/* ==========================================================================
   extras.css — hand-written styles for the interactive features.
   This file is NOT generated by Tailwind: edit it directly, no rebuild needed.
   ========================================================================== */

:root {
  --gold: #c6a45c;
  --champ: #e2d1a0;
  --line: #333333;
  --txt: #f2f2f2;
  --txt2: #b8b8b8;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ---------- 2. The name carries over from the welcome page to the hero ---------- */
@view-transition { navigation: auto; }
.vt-name { view-transition-name: swathi-name; }
::view-transition-group(root) { animation-duration: 0.4s; }
::view-transition-group(swathi-name) { animation-duration: 0.7s; animation-timing-function: var(--ease); }
@media (prefers-reduced-motion: reduce) { @view-transition { navigation: none; } }

/* ---------- 1. Light moving over the gold name ---------- */
.gold-light {
  background-image:
    radial-gradient(circle 170px at var(--mx, -999px) var(--my, -999px), #fffaf0 0%, rgba(255, 250, 240, 0) 100%),
    linear-gradient(#dcc88f, #dcc88f);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.dots-lit {
  background-image: radial-gradient(rgba(226, 209, 160, 0.9) 1px, transparent 1px);
  background-size: 14px 14px;
  -webkit-mask-image: radial-gradient(circle 200px at var(--px, -999px) var(--py, -999px), #000 0, transparent 100%);
  mask-image: radial-gradient(circle 200px at var(--px, -999px) var(--py, -999px), #000 0, transparent 100%);
}

/* ---------- 3. Scroll thread (left rail on wide screens, top line elsewhere) ---------- */
.topbar { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; pointer-events: none; }
.topbar-fill { display: block; height: 100%; width: calc(var(--progress, 0) * 100%); background: var(--gold); }
.rail { display: none; position: fixed; left: 28px; top: 50%; height: 56vh; width: 1px; transform: translateY(-50%); background: var(--line); z-index: 30; pointer-events: none; }
.rail-fill { position: absolute; left: 0; top: 0; width: 1px; height: calc(var(--progress, 0) * 100%); background: var(--gold); }
.rail a { position: absolute; left: -4px; width: 9px; height: 9px; border-radius: 50%; background: #000; border: 1px solid #555; transform: translateY(-50%); pointer-events: auto; transition: border-color 0.2s, background 0.2s; }
.rail a.past { border-color: var(--gold); }
.rail a.on { background: var(--gold); border-color: var(--gold); }
.rail a span { position: absolute; left: 20px; top: 50%; transform: translateY(-50%); white-space: nowrap; font-size: 13px; color: var(--txt2); opacity: 0; transition: opacity 0.2s; pointer-events: none; }
.rail a:hover span, .rail a:focus-visible span { opacity: 1; }
@media (min-width: 1280px) { .rail { display: block; } .topbar { display: none; } }

/* Navbar underline that glides between links */
.nav-glide { position: absolute; left: 0; bottom: -7px; height: 1px; width: 0; background: var(--gold); opacity: 0; pointer-events: none;
  transition: transform 0.35s var(--ease), width 0.35s var(--ease), opacity 0.2s; }

/* ---------- 9. Mobile menu: a structured list (phones and tablets only) ---------- */
.fs-menu { display: none; }
.js .fs-menu { display: flex; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0s linear 0.3s;
  background-image: radial-gradient(ellipse 80% 45% at 85% 0%, rgba(198, 164, 92, 0.13), transparent 70%),
                    radial-gradient(ellipse 70% 35% at 0% 100%, rgba(198, 164, 92, 0.08), transparent 70%); }
.js .fs-menu.open { opacity: 1; visibility: visible; transition-delay: 0s; }
body.menu-open { overflow: hidden; }
@media (min-width: 1024px) { .fs-menu { display: none !important; } }

.fs-head { display: flex; align-items: center; gap: 0.75rem; height: 50px; max-width: 24rem; width: 100%; margin: 0 auto; padding-right: 3.5rem; }
.fs-mono { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid rgba(198, 164, 92, 0.55); border-radius: 0.5rem;
  font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.05rem; color: var(--champ); }
.fs-name { font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.35rem; color: var(--txt); letter-spacing: 0.02em; }

.fs-menu > * { flex-shrink: 0; }
.fs-list { list-style: none; padding: 0; border-top: 1px solid var(--line); }
.fs-list li { position: relative; opacity: 0; transform: translateY(10px); }
.fs-menu.open .fs-list li { opacity: 1; transform: none; transition: opacity 0.4s ease, transform 0.4s var(--ease); transition-delay: calc(var(--i, 0) * 45ms + 0.1s); }
.fs-list li::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line); transform: scaleX(0); transform-origin: left; }
.fs-menu.open .fs-list li::after { transform: scaleX(1); transition: transform 0.6s var(--ease); transition-delay: calc(var(--i, 0) * 45ms + 0.25s); }
.fs-link { position: relative; display: flex; align-items: center; gap: 1rem; padding: 0.7rem 0.25rem; color: var(--txt); transition: background-color 0.2s, color 0.2s; }
.fs-ic { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 0.6rem; color: var(--gold); transition: border-color 0.2s, background-color 0.2s; }
.fs-label { flex: 1; font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.6rem; line-height: 1.1; }
.fs-go { flex: none; color: #6b6b6b; transition: color 0.2s, transform 0.2s var(--ease); }
.fs-link:active { background: rgba(198, 164, 92, 0.12); }
.fs-link:hover .fs-go { color: var(--gold); transform: translate(2px, -2px); }
.fs-link.active { color: var(--champ); background: linear-gradient(90deg, rgba(198, 164, 92, 0.14), transparent 80%); }
.fs-link.active::before { content: ""; position: absolute; left: -1px; top: 8px; bottom: 8px; width: 2px; border-radius: 2px; background: var(--gold); }
.fs-link.active .fs-ic { border-color: var(--gold); background: rgba(198, 164, 92, 0.12); }
.fs-link.active .fs-go { color: var(--gold); }

.fs-foot { opacity: 0; transform: translateY(10px); }
.fs-menu.open .fs-foot { opacity: 1; transform: none; transition: opacity 0.4s ease 0.55s, transform 0.4s var(--ease) 0.55s; }
.fs-cta { display: flex; align-items: center; justify-content: center; height: 3rem; border-radius: 999px; background: var(--gold); color: #000; font-size: 1.05rem; font-weight: 500; transition: background-color 0.2s, scale 0.15s; }
.fs-cta:hover { background: var(--champ); }
.fs-cta:active { scale: 0.98; }
.fs-soc { display: grid; place-items: center; width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 0.6rem; color: #c8c8c8; transition: border-color 0.2s, color 0.2s; }
.fs-soc:hover, .fs-soc:active { border-color: var(--gold); color: var(--gold); }

/* ---------- 4. Projects: cards that open to show how they work ---------- */
.proj summary { display: block; }
.proj .chev { transition: transform 0.25s var(--ease); }
.flow { position: relative; margin: 1rem 0 0; padding: 0 0 0 1.75rem; list-style: none; }
.flow::before, .flow::after { content: ""; position: absolute; left: 5px; top: 12px; bottom: 12px; width: 1px; }
.flow::before { background: var(--line); }
.flow::after { background: var(--gold); transform: scaleY(0); transform-origin: top; }
.flow li { position: relative; padding: 0.4rem 0; color: var(--txt2); font-size: 0.95rem; opacity: 0; transform: translateX(-6px); }
.flow li::before { content: ""; position: absolute; left: -1.75rem; top: 0.95rem; width: 11px; height: 11px; border-radius: 50%; background: #000; border: 1px solid var(--gold); }
details[open] .flow::after { transform: scaleY(1); transition: transform 0.9s var(--ease) 0.15s; }
details[open] .flow li { opacity: 1; transform: none; transition: opacity 0.4s ease, transform 0.4s var(--ease); transition-delay: calc(var(--i, 0) * 130ms + 0.15s); }

/* ---------- 5. Certifications: the arrow turns when a provider opens ---------- */
.chev { transition: transform 0.25s var(--ease); }
details[open] > summary .chev { transform: rotate(180deg); }

/* ---------- 6. Achievements timeline ---------- */
.timeline { position: relative; padding-left: 2.25rem; list-style: none; margin: 0; }
.timeline-line { position: absolute; left: 5px; top: 14px; bottom: 14px; width: 1px; background: var(--line); }
.timeline-fill { position: absolute; inset: 0; background: var(--gold); transform-origin: top; transform: scaleY(var(--tl, 0)); }
.tl-item { position: relative; padding-bottom: 2.75rem; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot { position: absolute; left: -2.25rem; top: 0.7rem; width: 11px; height: 11px; border-radius: 50%; background: #000; border: 1px solid #555; transition: background 0.3s, border-color 0.3s; }
.tl-item.on .tl-dot { background: var(--gold); border-color: var(--gold); }

/* ---------- 7. Interests: icons stay still; a small lift on hover ---------- */
.int-ic { transition: transform 0.3s var(--ease); }
.int-card:hover .int-ic, .int-card:focus-within .int-ic { transform: translateY(-3px); }

/* ---------- 8. Quiet detail polish ---------- */
.magnetic { transition: transform 0.25s var(--ease), background-color 0.2s, border-color 0.2s, color 0.2s; will-change: transform; }
.press:active { scale: 0.97; }

/* ---------- Reduced motion: everything stays still and readable ---------- */
@media (prefers-reduced-motion: reduce) {
  .flow li { opacity: 1; transform: none; }
  .flow::after { transform: scaleY(1); }
  .fs-list li, .fs-foot { opacity: 1; transform: none; }
  .fs-list li::after { transform: none; }
  .magnetic, .nav-glide, .fs-menu, .int-ic, .fs-list li, .fs-foot, .fs-go { transition: none; }
}

/* ---------- Welcome page: "Get to Know Me!" button ---------- */
.cta { position: relative; overflow: hidden; }
.cta::after { content: ""; position: absolute; inset: 0; pointer-events: none; transform: translateX(-130%);
  background: linear-gradient(105deg, transparent 38%, rgba(255, 250, 240, 0.5) 50%, transparent 62%); }
.cta .arr { display: inline-block; transition: transform 0.3s var(--ease); }
.cta:hover .arr, .cta:focus-visible .arr { transform: translateX(5px); }
@media (prefers-reduced-motion: no-preference) {
  .cta::after { animation: glint 1.2s var(--ease) 1.9s 1 both; }
  .cta:hover::after, .cta:focus-visible::after { animation: glint 0.8s var(--ease) 1 both; }
}
@keyframes glint { from { transform: translateX(-130%); } to { transform: translateX(130%); } }
