/* ============================================================
   sidharthan.com -- shared stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Caveat:wght@700&display=swap');

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --text:           #0F172A;
  --text-secondary: #64748B;
  --text-tertiary:  #94A3B8;
  --bg:             #FFFFFF;
  --surface:        #F8FAFC;
  --border:         #E2E8F0;
  --accent:         #2563EB;
  --accent-hover:   #1D4ED8;
  --accent-light:   #EFF6FF;
  --dark-bg:        #0F172A;
  --dark-text:      #F1F5F9;
  --dark-muted:     #94A3B8;
  --radius:         12px;
  --radius-sm:      8px;
  --shadow-sm:      0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md:      0 4px 16px rgba(0,0,0,.08), 0 2px 6px rgba(0,0,0,.05);
  --shadow-lg:      0 12px 40px rgba(0,0,0,.10), 0 4px 12px rgba(0,0,0,.06);
  --max-w:          1120px;
  --font:           'Inter', system-ui, sans-serif;
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; scroll-behavior: smooth; }
body { font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.6; }
a    { color: inherit; text-decoration: none; }
img  { display: block; max-width: 100%; }
ul   { list-style: none; }

/* ── Container ── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ── NAV ── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.site-nav.scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}
.nav-logo {
  font-family: 'Caveat', cursive;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
  transition: color 150ms, border-color 150ms;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active {
  color: var(--text);
  font-weight: 600;
  border-bottom-color: var(--accent);
}

/* Mobile nav toggle */
.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: var(--text);
  font-size: 22px;
  line-height: 1;
}
.nav-mobile-menu {
  display: none;
  flex-direction: column;
  padding: 12px 24px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg);
  gap: 2px;
}
.nav-mobile-menu.open { display: flex; }
.nav-mobile-menu a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  transition: color 150ms;
}
.nav-mobile-menu a:last-child { border-bottom: none; }
.nav-mobile-menu a:hover { color: var(--text); }

/* ── FOOTER ── */
.site-footer {
  background: var(--dark-bg);
  color: var(--dark-text);
  padding: 56px 0 40px;
}
.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 48px;
}
.footer-brand .footer-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}
.footer-brand p {
  font-size: 14px;
  color: var(--dark-muted);
  max-width: 300px;
  line-height: 1.7;
}
.footer-connect h3 {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--dark-muted);
  margin-bottom: 16px;
}
.footer-social {
  display: flex;
  gap: 12px;
}
.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
  color: var(--dark-text);
  font-size: 16px;
  transition: background 150ms, transform 150ms;
}
.footer-social a:hover { background: rgba(255,255,255,0.15); transform: translateY(-2px); }
.footer-cal a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  font-size: 13px;
  color: var(--dark-muted);
  transition: color 150ms;
}
.footer-cal a:hover { color: var(--dark-text); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  font-size: 13px;
  color: var(--dark-muted);
}

/* ── PAGE HEADER (inner pages) ── */
.page-header {
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 64px;
}
.page-header h1 {
  font-size: 42px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}
.page-header p {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.65;
}

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 150ms, color 150ms, transform 120ms, box-shadow 150ms;
  border: none;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); box-shadow: 0 4px 14px rgba(37,99,235,0.35); }
.btn-outline { background: transparent; color: var(--accent); border: 1.5px solid var(--accent); }
.btn-outline:hover { background: var(--accent-light); }

/* ── BACK LINK ── */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 32px;
  transition: color 150ms, gap 150ms;
}
.back-link:hover { color: var(--accent); gap: 10px; }
.back-link .arrow { font-style: normal; }

/* ── CASE STUDY DETAIL ── */
.cs-detail-wrap { max-width: 720px; }
.cs-detail-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--accent-light);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 20px;
}
.cs-detail-title {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 48px;
}
.cs-section { margin-bottom: 48px; }
.cs-section h2 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin-bottom: 16px;
}
.cs-section p {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.75;
}
.cs-section p + p { margin-top: 16px; }
.cs-section ul {
  list-style: disc;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cs-section ul li {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ── CASE STUDY DETAIL IMAGE ── */
.cs-detail-actions { margin-top: 40px; }
.cs-detail-image {
  margin-top: 48px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
.cs-detail-image img { width: 100%; height: auto; display: block; }

/* ── FORM ── */
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.form-group label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}
.form-group input,
.form-group textarea {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  transition: border-color 150ms, box-shadow 150ms;
  outline: none;
  width: 100%;
}
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
}
.form-group textarea { resize: vertical; min-height: 140px; }
.form-status { font-size: 14px; margin-top: 12px; min-height: 20px; }
.form-status.success { color: #16a34a; }
.form-status.error   { color: #dc2626; }

/* ── PASSWORD GATE ── */
.gate-wrap {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
}
.gate-card {
  width: 100%;
  max-width: 400px;
  text-align: center;
}
.gate-card .gate-icon {
  font-size: 40px;
  margin-bottom: 24px;
}
.gate-card h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.gate-card p {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 28px;
  line-height: 1.65;
}
.gate-card input {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  width: 100%;
  margin-bottom: 12px;
  outline: none;
  transition: border-color 150ms, box-shadow 150ms;
  text-align: center;
  letter-spacing: 0.1em;
}
.gate-card input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
}
.gate-error {
  font-size: 13px;
  color: #dc2626;
  margin-top: 8px;
  min-height: 18px;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-mobile-toggle { display: block; }

  .footer-inner { flex-direction: column; gap: 32px; }

  .page-header h1 { font-size: 30px; }
  .page-header p  { font-size: 16px; }

  .cs-detail-title { font-size: 28px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
}
