/* ════════════════════════════════════════════════
   Vionna — Global Stylesheet
   Purple + White · Dark Mode · RTL (Vazirmatn)
   ════════════════════════════════════════════════ */

/* ── Variables ─────────────────────────────────── */
:root {
  --primary:       #7C3AED;
  --primary2:      #A78BFA;
  --bg:            #0B0B12;
  --bg2:           #14141f;
  --bg3:           #1c1c2a;
  --text:          #F5F5FA;
  --muted:         #8888a0;
  --border:        rgba(255,255,255,0.08);
  --border-accent: rgba(124,58,237,0.35);
  --nav-h:         72px;
  --radius:        16px;
}

/* ── Light Mode Variables ───────────────────────── */
html[data-theme="light"] {
  --bg:            #F4F4FB;
  --bg2:           #FFFFFF;
  --bg3:           #ECECF6;
  --text:          #111128;
  --muted:         #5E5E78;
  --border:        rgba(0,0,0,0.09);
  --border-accent: rgba(124,58,237,0.28);
}

/* ── Reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Vazirmatn', 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  direction: rtl;
  overflow-x: hidden;
  line-height: 1.7;
  transition: background-color .3s ease, color .3s ease;
}

img, svg { display: block; }
a { color: inherit; }
button { cursor: pointer; font-family: inherit; }

/* ── Container ─────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
}

/* ════════════════════════════════════════════════
   NAV
   ════════════════════════════════════════════════ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4rem;
  background: rgba(11,11,18,0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 0.5px solid var(--border);
  transition: background .3s, border-color .3s;
}
.nav.scrolled { background: rgba(11,11,18,0.95); }

html[data-theme="light"] .nav { background: rgba(244,244,251,0.80); }
html[data-theme="light"] .nav.scrolled { background: rgba(244,244,251,0.97); }

/* ── Theme Toggle Button ────────────────────────── */
.theme-toggle {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: var(--bg3);
  border: 0.5px solid var(--border);
  color: var(--muted);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color .2s, color .2s, background-color .3s;
}
.theme-toggle:hover { border-color: var(--primary); color: var(--primary2); }
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun  { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: block; }

.nav__brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -.01em;
  flex-shrink: 0;
}
.nav__logo { width: 32px; height: 32px; flex-shrink: 0; }

.nav__links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}
.nav__links a {
  color: var(--muted);
  text-decoration: none;
  font-size: .92rem;
  transition: color .2s;
  white-space: nowrap;
}
.nav__links a:hover { color: var(--text); }
.nav__links a.active { color: var(--primary2); }

.nav__cta {
  background: var(--primary) !important;
  color: #fff !important;
  padding: .5rem 1.15rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: .9rem !important;
  transition: opacity .2s, transform .2s;
}
.nav__cta:hover { opacity: .88; transform: translateY(-1px); }

/* ════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════ */
.footer {
  background: var(--bg);
  border-top: 0.5px solid var(--border);
  padding: 4rem 4rem 2rem;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer__brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: .65rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: .5rem;
}
.footer__blurb {
  color: var(--muted);
  font-size: .875rem;
  line-height: 1.85;
  max-width: 280px;
}
.footer__heading {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--muted);
  margin-bottom: 1.1rem;
}
.footer__links { list-style: none; display: flex; flex-direction: column; gap: .55rem; }
.footer__links a {
  color: var(--muted);
  text-decoration: none;
  font-size: .875rem;
  transition: color .2s;
}
.footer__links a:hover { color: var(--primary2); }

.footer__socials { display: flex; gap: .75rem; margin-top: .25rem; }
.footer__social-icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--bg2);
  border: 0.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--muted);
  text-decoration: none;
  font-size: .95rem;
  transition: border-color .2s, color .2s, transform .2s;
}
.footer__social-icon:hover {
  border-color: var(--primary);
  color: var(--primary2);
  transform: translateY(-2px);
}

.footer__bottom {
  border-top: 0.5px solid var(--border);
  padding-top: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer__copy { color: var(--muted); font-size: .82rem; }

/* ════════════════════════════════════════════════
   UTILITIES
   ════════════════════════════════════════════════ */

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.on { opacity: 1; transform: none; }

/* Stagger delay helpers */
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }
.reveal-delay-5 { transition-delay: .5s; }

/* Eyebrow badge */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  font-size: .8rem;
  font-weight: 600;
  color: var(--primary2);
  border: 0.5px solid var(--border-accent);
  border-radius: 999px;
  padding: .35rem 1rem;
  margin-bottom: 1.25rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.eyebrow .dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--primary);
  flex-shrink: 0;
  animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%,100% { opacity:1; transform:scale(1); }
  50%      { opacity:.4; transform:scale(1.6); }
}

/* Section header */
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-eyebrow {
  display: inline-block;
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--primary);
  margin-bottom: .65rem;
}
.section-h2 {
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1.25;
}
.section-desc {
  color: var(--muted);
  max-width: 560px;
  margin: .85rem auto 0;
  line-height: 1.85;
  font-size: .95rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .8rem 1.9rem;
  border-radius: 10px;
  font-size: .95rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  transition: transform .2s, opacity .2s, border-color .2s, color .2s;
  white-space: nowrap;
}
.btn--primary {
  background: var(--primary);
  color: #fff;
}
.btn--primary:hover { opacity: .87; transform: translateY(-2px); }

.btn--ghost {
  background: transparent;
  color: var(--text);
  border: 0.5px solid var(--border-accent);
}
.btn--ghost:hover { border-color: var(--primary2); color: var(--primary2); transform: translateY(-2px); }

.btn-group { display: flex; gap: 1rem; flex-wrap: wrap; }

/* Tags */
.tag {
  display: inline-block;
  padding: .2rem .65rem;
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 600;
  background: rgba(124,58,237,0.12);
  color: var(--primary2);
  border: 0.5px solid var(--border-accent);
}

/* ════════════════════════════════════════════════
   HOME — HERO
   ════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: var(--nav-h);
}

#circuit-canvas {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  opacity: .65;
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 820px;
  padding: 0 2rem;
}

.hero__h1 {
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  font-weight: 900;
  line-height: 1.22;
  margin-bottom: 1.2rem;
  color: var(--text);
}
.hero__h1 em { color: var(--primary); font-style: normal; }

.hero__subtitle {
  font-size: 1.08rem;
  color: var(--muted);
  max-width: 540px;
  margin: 0 auto 2.2rem;
  line-height: 1.85;
}

.hero__cta { justify-content: center; margin-bottom: 3.5rem; }

.hero__stats {
  display: flex;
  gap: 3rem;
  justify-content: center;
  flex-wrap: wrap;
  border-top: 0.5px solid var(--border);
  padding-top: 2.5rem;
}
.stat__num {
  display: block;
  font-size: 2rem;
  font-weight: 900;
  color: var(--primary2);
  line-height: 1;
  margin-bottom: .3rem;
}
.stat__label { font-size: .8rem; color: var(--muted); }

/* ════════════════════════════════════════════════
   HOME — BRAND INTRO
   ════════════════════════════════════════════════ */
.brand-intro { background: var(--bg2); padding: 7rem 4rem; }
.brand-intro__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.brand-intro__text h2 {
  font-size: clamp(1.6rem, 2.5vw, 2rem);
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 1.2rem;
  color: var(--text);
}
.brand-intro__text p {
  color: var(--muted);
  line-height: 1.9;
  margin-bottom: 1.75rem;
  font-size: .95rem;
}
.brand-intro__visual {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
}

/* Geometric abstract visual */
.geo-visual { width: 280px; height: 280px; position: relative; }
.geo-visual svg { width: 100%; height: 100%; }

/* ════════════════════════════════════════════════
   HOME — SERVICES
   ════════════════════════════════════════════════ */
.services-section { padding: 7rem 4rem; }
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.service-card {
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: border-color .3s, transform .3s;
}
.service-card:hover { border-color: var(--primary); transform: translateY(-4px); }

.service-card__icon {
  width: 48px; height: 48px;
  background: rgba(124,58,237,0.12);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.2rem;
  color: var(--primary2);
}
.service-card__title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: .5rem;
  color: var(--text);
}
.service-card__desc {
  color: var(--muted);
  font-size: .875rem;
  line-height: 1.75;
}

/* ════════════════════════════════════════════════
   HOME — PORTFOLIO PREVIEW
   ════════════════════════════════════════════════ */
.portfolio-section { background: var(--bg2); padding: 7rem 4rem; }
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}
.project-card {
  background: var(--bg3);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .3s, transform .3s;
}
.project-card:hover { border-color: var(--primary); transform: translateY(-4px); }

.project-card__img {
  width: 100%; height: 200px;
  background: linear-gradient(135deg, rgba(124,58,237,0.18) 0%, rgba(167,139,250,0.08) 100%);
  display: flex; align-items: center; justify-content: center;
  border-bottom: 0.5px solid var(--border);
  color: var(--primary2);
}
.project-card__body { padding: 1.5rem; }
.project-card__title { font-weight: 700; font-size: .95rem; margin-bottom: .35rem; }
.project-card__desc {
  color: var(--muted);
  font-size: .85rem;
  margin-bottom: .85rem;
  line-height: 1.7;
}
.portfolio-more { text-align: center; }

/* ════════════════════════════════════════════════
   CTA BAND (shared)
   ════════════════════════════════════════════════ */
.cta-band {
  background: linear-gradient(135deg, var(--bg2), var(--bg3));
  border-top: 0.5px solid var(--border);
  border-bottom: 0.5px solid var(--border);
  padding: 6rem 4rem;
  text-align: center;
}
.cta-band h2 {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  font-weight: 800;
  margin-bottom: .75rem;
  color: var(--text);
}
.cta-band p {
  color: var(--muted);
  font-size: .95rem;
  margin-bottom: 2rem;
  max-width: 480px;
  margin-left: auto; margin-right: auto;
}
.cta-band .btn-group { justify-content: center; }

/* ════════════════════════════════════════════════
   PAGE HERO (about / contact — no canvas)
   ════════════════════════════════════════════════ */
.page-hero {
  min-height: 42vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-h) + 5rem) 4rem 5rem;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(0deg,   transparent, transparent 59px, rgba(124,58,237,0.045) 59px, rgba(124,58,237,0.045) 60px),
    repeating-linear-gradient(90deg,  transparent, transparent 59px, rgba(124,58,237,0.045) 59px, rgba(124,58,237,0.045) 60px);
  z-index: 0;
}
.page-hero::after {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 60% at 50% 0%, rgba(124,58,237,0.12) 0%, transparent 70%);
  z-index: 0;
}
.page-hero__content {
  position: relative;
  z-index: 1;
  max-width: 700px;
}
.page-hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  font-weight: 900;
  margin-bottom: 1rem;
  line-height: 1.22;
  color: var(--text);
}
.page-hero p { color: var(--muted); font-size: 1.05rem; line-height: 1.85; max-width: 500px; margin: 0 auto; }

/* ════════════════════════════════════════════════
   ABOUT — MISSION
   ════════════════════════════════════════════════ */
.mission-section { padding: 7rem 4rem; }
.mission-inner { max-width: 760px; margin: 0 auto; }
.mission-inner p {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.95;
  margin-bottom: 1.5rem;
}
.mission-inner p:last-of-type { margin-bottom: 0; }

.stat-row {
  display: flex;
  gap: 3rem;
  margin-top: 3rem;
  padding-top: 3rem;
  border-top: 0.5px solid var(--border);
  flex-wrap: wrap;
}
.stat-row .stat { text-align: center; }

/* ════════════════════════════════════════════════
   ABOUT — VALUES
   ════════════════════════════════════════════════ */
.values-section { background: var(--bg2); padding: 7rem 4rem; }
.values-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.value-card {
  background: var(--bg3);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  transition: border-color .3s, transform .3s;
}
.value-card:hover { border-color: var(--primary); transform: translateY(-4px); }
.value-card__icon {
  width: 44px; height: 44px;
  background: rgba(124,58,237,0.12);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
  color: var(--primary2);
}
.value-card__title { font-weight: 700; font-size: .95rem; margin-bottom: .45rem; color: var(--text); }
.value-card__desc { color: var(--muted); font-size: .855rem; line-height: 1.7; }

/* ════════════════════════════════════════════════
   ABOUT — PROCESS
   ════════════════════════════════════════════════ */
.process-section { padding: 7rem 4rem; }
.process-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.process-step {
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: border-color .3s, transform .3s;
}
.process-step:hover { border-color: var(--primary); transform: translateY(-4px); }
.process-step__num {
  font-size: 2.8rem;
  font-weight: 900;
  color: rgba(124,58,237,0.18);
  line-height: 1;
  margin-bottom: .75rem;
  font-variant-numeric: tabular-nums;
}
.process-step__title { font-weight: 700; font-size: .95rem; margin-bottom: .45rem; color: var(--text); }
.process-step__desc { color: var(--muted); font-size: .855rem; line-height: 1.7; }

/* ════════════════════════════════════════════════
   CONTACT — LAYOUT
   ════════════════════════════════════════════════ */
.contact-section { padding: 5rem 4rem 7rem; }
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 3rem;
  align-items: start;
}
.contact-info h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 1.5rem; color: var(--text); }

.contact-channels { display: flex; flex-direction: column; gap: .85rem; margin-bottom: 1.5rem; }
.channel-card {
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: 12px;
  padding: 1.1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: border-color .2s;
  text-decoration: none;
  color: inherit;
}
.channel-card:hover { border-color: var(--primary); }
.channel-card__icon {
  width: 40px; height: 40px;
  background: rgba(124,58,237,0.12);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--primary2);
  flex-shrink: 0;
}
.channel-card__label {
  font-size: .72rem;
  color: var(--muted);
  display: block;
  margin-bottom: .15rem;
}
.channel-card__value { font-size: .92rem; font-weight: 600; color: var(--text); }

.response-note {
  background: rgba(124,58,237,0.06);
  border: 0.5px solid var(--border-accent);
  border-radius: 10px;
  padding: .9rem 1.1rem;
  color: var(--muted);
  font-size: .855rem;
  display: flex;
  align-items: center;
  gap: .65rem;
  margin-top: 1.25rem;
}

/* Contact form */
.contact-form {
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem;
}
.contact-form h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 1.75rem; color: var(--text); }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin-bottom: .9rem;
}
.form-group label { font-size: .855rem; font-weight: 600; color: var(--text); }

.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg);
  border: 0.5px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: .92rem;
  padding: .72rem 1rem;
  outline: none;
  transition: border-color .2s;
  direction: rtl;
  width: 100%;
  -webkit-appearance: none;
}
.form-group select { cursor: pointer; }
.form-group select option { background: var(--bg2); }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--primary); }
.form-group textarea { resize: vertical; min-height: 130px; }

.btn--submit {
  width: 100%;
  justify-content: center;
  margin-top: .5rem;
  padding: .9rem;
  font-size: .95rem;
}
.btn--submit:disabled { opacity: .65; cursor: not-allowed; transform: none; }
.form-feedback {
  margin-top: .85rem;
  text-align: center;
  font-size: .875rem;
  min-height: 1.4em;
  color: var(--primary2);
}
.form-feedback--success { color: #4ade80; }
.form-feedback--error   { color: #f87171; }

/* ════════════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .brand-intro__inner      { grid-template-columns: 1fr; }
  .brand-intro__visual     { display: none; }
  .services-grid           { grid-template-columns: 1fr 1fr; }
  .values-grid             { grid-template-columns: 1fr 1fr; }
  .process-steps           { grid-template-columns: 1fr 1fr; }
  .portfolio-grid          { grid-template-columns: 1fr 1fr; }
  .contact-layout          { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .nav { padding: 0 1.5rem; }
  .nav__links li:not(:last-child) { display: none; }
  .services-grid  { grid-template-columns: 1fr 1fr; }
  .values-grid    { grid-template-columns: 1fr 1fr; }
}

/* Center lone 7th card in 3-column services grid */
@media (min-width: 1025px) {
  .services-grid .service-card:last-child:nth-child(3n+1) {
    grid-column: 2;
  }
}

@media (max-width: 768px) {
  .brand-intro,
  .services-section,
  .portfolio-section,
  .mission-section,
  .values-section,
  .process-section,
  .contact-section { padding: 5rem 1.5rem; }
  .cta-band   { padding: 5rem 1.5rem; }
  .footer     { padding: 3rem 1.5rem 1.5rem; }
  .page-hero  { padding: calc(var(--nav-h) + 3rem) 1.5rem 3rem; }

  .footer__grid      { grid-template-columns: 1fr; gap: 2rem; }
  .footer__bottom    { flex-direction: column; gap: .75rem; text-align: center; }

  .services-grid  { grid-template-columns: 1fr; }
  .values-grid    { grid-template-columns: 1fr; }
  .portfolio-grid { grid-template-columns: 1fr; }
  .process-steps  { grid-template-columns: 1fr; }
  .contact-layout { grid-template-columns: 1fr; }
  .form-row       { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════
   LAPTOP MOCKUP
   ════════════════════════════════════════════════ */
.laptop-mockup {
  background: #1c1c2e;
  border-radius: 9px 9px 0 0;
  padding: 6px 6px 0;
  border: 0.5px solid rgba(124,58,237,0.28);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.04);
}
.laptop-mockup__camera {
  height: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 5px;
}
.laptop-mockup__camera::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: rgba(124,58,237,0.5);
  box-shadow: 0 0 5px rgba(124,58,237,0.45);
}
.laptop-mockup__screen {
  border-radius: 4px;
  overflow: hidden;
  aspect-ratio: 16/10;
  background: #0d0d1a;
  position: relative;
}
.laptop-mockup__screen img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.project-card:hover .laptop-mockup__screen img {
  transform: scale(1.04);
}
.laptop-base {
  height: 13px;
  background: #141420;
  border-radius: 0 0 8px 8px;
  border: 0.5px solid rgba(124,58,237,0.18);
  border-top: none;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 2px;
  margin-bottom: 1.5rem;
}
.laptop-base::after {
  content: '';
  width: 26%;
  height: 3px;
  background: rgba(124,58,237,0.2);
  border-radius: 2px 2px 0 0;
}

/* ── Project card: cursor + smooth tilt reset ─── */
.project-card[data-modal] {
  cursor: pointer;
  transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
  will-change: transform;
}
.project-card[data-modal]:hover {
  border-color: var(--primary);
  box-shadow: 0 16px 48px rgba(124,58,237,0.14);
}
.project-card.tilt-reset {
  transition: transform .45s ease, border-color .25s ease, box-shadow .25s ease;
}

/* ── Portfolio visual wrapper (replaces fixed-height img div) */
.project-card__visual {
  padding: 1.1rem 1.1rem 0;
}

/* ════════════════════════════════════════════════
   MODAL
   ════════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(11,11,18,0.84);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.modal-box {
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem;
  max-width: 580px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  transform: scale(.93);
  transition: transform .25s ease;
  position: relative;
  scrollbar-width: thin;
  scrollbar-color: var(--border-accent) transparent;
}
.modal-overlay.open .modal-box { transform: scale(1); }

.modal-close {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  width: 34px; height: 34px;
  border-radius: 8px;
  background: var(--bg3);
  border: 0.5px solid var(--border);
  color: var(--muted);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: color .2s, border-color .2s;
}
.modal-close:hover { color: var(--text); border-color: var(--primary); }
.modal-close svg { pointer-events: none; }

.modal-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 1.5rem;
  padding-left: 2.75rem;
  line-height: 1.5;
}

.modal-body { display: flex; flex-direction: column; gap: .4rem; }
.modal-body p {
  color: var(--muted);
  font-size: .875rem;
  line-height: 1.85;
}
.modal-body ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin: .25rem 0;
}
.modal-body ul li {
  color: var(--muted);
  font-size: .875rem;
  line-height: 1.7;
  display: flex;
  gap: .5rem;
  align-items: flex-start;
}
.modal-body ul li::before {
  content: '—';
  color: var(--primary2);
  flex-shrink: 0;
  margin-top: .05em;
}
.modal-subsection { margin-top: 1rem; }
.modal-subsection-title {
  font-size: .78rem;
  font-weight: 700;
  color: var(--primary2);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .4rem;
}

@media (max-width: 768px) {
  .modal-box { padding: 1.75rem 1.25rem; }
  .modal-title { font-size: 1rem; }
}

html[data-theme="light"] .modal-overlay {
  background: rgba(180,180,210,0.70);
}
