:root {
  --nav-bg: rgba(255, 255, 255, 0.95);
  --nav-text: #000;
  --transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* THEME VARIABLES */
body[data-theme="slate-glass"] {
  --font-heading: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --bg-primary: #ffffff;
  --bg-secondary: #f5f5f5;
  --text-main: #000000;
  --text-muted: #666666;
  --border-color: #e5e5e5;
  --accent: #000000;
}

body[data-theme="slate"] { --hero-img: url('./abstract_device_mockup_1_1780808612518.png'); }
body[data-theme="slate-gradient"] { --hero-img: url('./abstract_device_mockup_2_1780808625043.png'); }
body[data-theme="slate-glass"] { --hero-img: url('./abstract_device_mockup_3_1780808636794.png'); }

/* GLOBAL STYLES */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body { 
  font-family: var(--font-body); 
  background-color: var(--bg-primary); 
  color: var(--text-main); 
  -webkit-font-smoothing: antialiased; 
  transition: var(--transition); 
  overflow-x: hidden;
}

h1, h2, h3, .nav-logo { font-family: var(--font-heading); transition: var(--transition); }
.container { max-width: 1400px; margin: 0 auto; padding: 0 40px; }
.mono-text { font-family: 'JetBrains Mono', monospace; font-size: 13px; letter-spacing: 0.1em; color: var(--text-muted); text-transform: uppercase;}



/* Navigation */
.site-nav { position: fixed; top: 0; left: 0; width: 100%; padding: 32px 0; background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(10px); z-index: 2005; transition: var(--transition); }
.nav-container { display: flex; justify-content: space-between; align-items: center; }
.nav-logo { font-size: 24px; font-weight: 700; text-decoration: none; color: var(--text-main); letter-spacing: -0.02em;}
.nav-links { display: flex; gap: 48px; }
.nav-links a { text-decoration: none; color: var(--text-main); font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; transition: color 0.3s; }
.btn-solid { display: inline-block; background: var(--text-main); color: var(--bg-primary); padding: 16px 32px; text-decoration: none; font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; transition: all 0.3s ease; border-radius: 0; border: 1px solid var(--text-main); }
.btn-solid:hover { background: transparent; color: var(--text-main); transform: translateY(-2px); }

/* Mobile Menu */
.mobile-menu-toggle { display: none; background: transparent; color: var(--text-main); border: none; font-size: 13px; font-weight: 600; font-family: var(--font-body); text-transform: uppercase; letter-spacing: 0.05em; cursor: pointer; }
/* .mobile-menu-close removed */
.mobile-menu-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: var(--bg-primary); z-index: 2000; display: flex; flex-direction: column; justify-content: center; align-items: center; opacity: 0; pointer-events: none; transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
.mobile-menu-overlay.active { opacity: 1; pointer-events: auto; }
.mobile-menu-links { display: flex; flex-direction: column; gap: 40px; text-align: center; }
.mobile-menu-links a { font-family: var(--font-heading); font-size: clamp(3rem, 10vw, 4rem); font-weight: 500; color: var(--text-main); text-decoration: none; letter-spacing: -0.02em; transition: opacity 0.3s; }
.mobile-menu-links a:hover { opacity: 0.5; }

/* Structured Hero */
.hero-section { padding-top: clamp(140px, 15vw, 180px); padding-bottom: clamp(40px, 10vw, 120px); min-height: 100vh; display: flex; align-items: center; }
.hero-container { display: flex; gap: 120px; align-items: stretch; width: 100%; }
.hero-left { flex: 1; display: flex; flex-direction: column; justify-content: center; }
.hero-content-wrapper { max-width: 600px; }
.hero-right { flex: 1; min-height: 70vh; }
.hero-image-block { width: 100%; height: 100%; background-image: var(--hero-img); background-size: cover; background-position: center; filter: grayscale(10%); }

.hero-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border-color); padding-bottom: 32px; margin-bottom: clamp(32px, 6vw, 60px); font-size: 13px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em;}
.status-badge { display: flex; align-items: center; gap: 12px; color: var(--text-main); }
.status-badge .dot { width: 10px; height: 10px; background: #10B981; border-radius: 0; }

.hero-title { font-size: clamp(3.5rem, 6vw, 6rem); font-weight: 500; line-height: 1.05; letter-spacing: -0.04em; margin-bottom: clamp(24px, 5vw, 48px); }
.hero-title i { font-style: normal; color: var(--text-muted); font-weight: 400;}
.hero-subtitle { font-size: 18px; line-height: 1.6; color: var(--text-muted); font-weight: 400; }

/* Sections Common */
.section-intro { margin-bottom: clamp(40px, 8vw, 80px); max-width: 800px; }
.section-title { font-size: clamp(3rem, 5vw, 4.5rem); font-weight: 500; line-height: 1.1; margin-bottom: 24px; letter-spacing: -0.03em;}
.work-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: clamp(40px, 8vw, 80px); }

/* Layout Controls */
.layout-controls { display: flex; gap: 8px; align-items: center; }
.layout-controls span { font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); margin-right: 16px; font-weight: 500;}
.layout-btn { background: transparent; border: 1px solid var(--border-color); color: var(--text-muted); padding: 12px 24px; font-size: 13px; font-family: var(--font-body); cursor: pointer; transition: var(--transition); border-radius: 0;}
.layout-btn:hover { border-color: var(--text-main); color: var(--text-main); }
.layout-btn.active { background: var(--text-main); color: var(--bg-primary); border-color: var(--text-main); }

/* Animation Logic */
@keyframes fade-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* -------------------------------------
   SERVICES (Locked: Brutalist Grid)
   ------------------------------------- */
.services-section { padding: clamp(80px, 12vw, 160px) 0; background: var(--bg-primary); }

.brutalist-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border-color); border: 1px solid var(--border-color); }
.brutalist-card { background: var(--bg-primary); padding: 80px 60px; transition: var(--transition); display: flex; flex-direction: column; gap: 32px; }
.brutalist-num { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); font-family: var(--font-body); border-bottom: 1px solid currentColor; padding-bottom: 8px; display: inline-block; width: fit-content;}
.brutalist-title { font-size: 32px; font-weight: 500; line-height: 1.1; letter-spacing: -0.02em; }
.brutalist-desc { font-size: 18px; line-height: 1.6; color: var(--text-muted); transition: var(--transition);}

/* -------------------------------------
   PROCESS (Locked: Schematic/Flowchart)
   ------------------------------------- */
.process-section { padding: clamp(80px, 12vw, 160px) 0; background: var(--bg-primary); border-top: 1px solid var(--border-color); }

.gantt-wrapper { border: 1px solid var(--border-color); background: transparent; }
.gantt-header { display: grid; grid-template-columns: 200px 1fr 1fr 1fr 1fr; border-bottom: 1px solid var(--border-color); background: transparent; }
.gantt-header span { padding: 16px 24px; border-right: 1px solid var(--border-color); }
.gantt-header span:last-child { border-right: none; }
.gantt-header span:first-child { grid-column: 2; }
.gantt-row { display: grid; grid-template-columns: 200px 1fr; border-bottom: 1px solid var(--border-color); }
.gantt-row:last-child { border-bottom: none; }
.gantt-label { padding: 24px; border-right: 1px solid var(--border-color); font-weight: 500; font-size: 32px; letter-spacing: -0.02em;}
.gantt-track { padding: 24px; display: flex; align-items: center; position: relative;}
.gantt-track::before { content:''; position:absolute; top:0; bottom:0; left:25%; width:1px; background: var(--border-color); opacity: 0.5;}
.gantt-track::after { content:''; position:absolute; top:0; bottom:0; left:50%; width:1px; background: var(--border-color); opacity: 0.5;}
.gantt-bar { height: 16px; background: var(--text-main); }

/* -------------------------------------
   GRID UTILITIES & WORK
   ------------------------------------- */
.work-section { padding: clamp(80px, 12vw, 160px) 0; overflow: hidden; background: var(--bg-primary);}

/* Shared Work Styles */
.gallery-tag { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); }
.gallery-result { font-size: 32px; color: var(--text-main); font-weight: 500; letter-spacing: -0.02em;}
.gallery-desc { font-size: 18px; line-height: 1.6; color: var(--text-muted); }

/* V3: 2-Col Grid */
.two-col-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }

/* Blog Grid */
.blog-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--border-color); border-top: 1px solid var(--border-color); }

.tc-card { display: flex; flex-direction: column; gap: 24px; padding: 40px; border: 1px solid var(--border-color); transition: transform 0.3s; cursor: pointer; }
.tc-card:hover { transform: translateY(-5px); box-shadow: 0 20px 40px rgba(0,0,0,0.05); }
.tc-img { width: 100%; aspect-ratio: 16/10; overflow: hidden; background: var(--bg-secondary); }
.tc-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.tc-card:hover .tc-img img { transform: scale(1.04); }
.tc-info { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--border-color); padding-top: 24px; }
.tc-info .gallery-tag { font-size: 13px; }
.tc-info .gallery-result { font-size: 32px; letter-spacing: -0.02em; }

/* -------------------------------------
   TESTIMONIALS (Locked: Grid)
   ------------------------------------- */
.testimonials-section { background-color: var(--bg-primary); padding: clamp(40px, 10vw, 160px) 0; border-top: 1px solid var(--border-color);}

.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.testimonial-card { display: flex; flex-direction: column; gap: 32px; padding: 60px; border: 1px solid var(--border-color); }
.stars { color: var(--text-main); font-size: 16px; letter-spacing: 2px; }
.quote { font-family: var(--font-body); line-height: 1.6; font-weight: 400; color: var(--text-main); flex: 1; font-size: 20px;}
.author { font-size: 13px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; border-top: 1px solid var(--border-color); padding-top: 24px;}

/* -------------------------------------
   FOOTER (Locked: Classic)
   ------------------------------------- */
.classic-footer { background-color: var(--text-main); color: var(--bg-primary); padding: clamp(40px, 10vw, 160px) 0 60px; transition: var(--transition); }
.footer-cta { text-align: center; margin-bottom: clamp(40px, 10vw, 160px); }
.footer-cta h2 { font-size: clamp(4rem, 8vw, 8rem); font-weight: 500; letter-spacing: -0.04em; margin-bottom: clamp(32px, 6vw, 60px); color: var(--bg-primary); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 60px; }
.footer-logo { font-size: 40px; font-weight: 700; font-family: var(--font-heading); color: var(--bg-primary); letter-spacing: -0.02em;}
.footer-links { display: flex; gap: 60px; }
.footer-links a { color: var(--bg-primary); text-decoration: none; font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; opacity: 0.7; transition: opacity 0.3s; }
.footer-links a:hover { opacity: 1; }
.footer-copy { font-size: 13px; font-weight: 600; color: var(--bg-primary); opacity: 0.5; text-transform: uppercase; letter-spacing: 0.05em; }
.cta-link { display: inline-block; background: var(--bg-primary); color: var(--text-main); padding: 24px 48px; text-decoration: none; font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; transition: transform 0.3s ease; }
.cta-link:hover { transform: translateY(-4px); }


@media (max-width: 1024px) {
  .hero-container { flex-direction: column; gap: 60px; }
  .hero-right { min-height: 400px; }
  .brutalist-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .gantt-header { display: none; }
  .gantt-row { grid-template-columns: 120px 1fr; }
  .gantt-label { font-size: 16px; }
  .two-col-grid { grid-template-columns: 1fr; }
  .testimonial-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 40px; text-align: center; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .btn-solid { display: none; }
  .mobile-menu-toggle { display: block; padding: 12px 0; }
  /* .mobile-menu-close removed */
  .theme-switcher { width: 100%; bottom: 0; padding: 12px; flex-wrap: wrap; }
  .theme-btn { padding: 12px; font-size: 11px; flex: 1; text-align: center; }
  .work-header { flex-direction: column; align-items: flex-start; gap: 32px; }
  .layout-controls { flex-wrap: wrap; }
  .hero-right { display: none; }
  .about-flex { flex-direction: column !important; }
  .about-img-wrapper { width: 100% !important; margin: 0 0 40px 0 !important; }
}

/* -------------------------------------
   MIGRATED PAGES (About, Blog, Contact, Work)
   ------------------------------------- */

.page-header { padding-top: clamp(140px, 15vw, 180px); padding-bottom: clamp(40px, 8vw, 80px); }
.page-content { padding-bottom: clamp(80px, 15vw, 180px); }
.heading-massive { font-size: clamp(3.5rem, 6vw, 6rem); font-family: var(--font-heading); font-weight: 500; line-height: 1.05; letter-spacing: -0.04em; color: var(--text-main); }
.heading-card { font-size: 32px; font-family: var(--font-heading); font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; color: var(--text-main); }
.body-text { font-size: 18px; font-family: var(--font-body); line-height: 1.6; color: var(--text-muted); }
.label-text { font-size: 13px; font-family: var(--font-body); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-main); }

/* Footer Overrides */
.site-footer { background-color: var(--text-main); color: var(--bg-primary); padding: clamp(60px, 10vw, 100px) 0 40px; }
.site-footer a, .site-footer p { color: var(--bg-primary); }
.footer-grid { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 80px; margin-bottom: clamp(40px, 8vw, 80px); }
.footer-brand .nav-logo { color: var(--bg-primary); margin-bottom: 24px; display: block; }
.footer-desc { font-size: 14px; opacity: 0.6; max-width: 280px; }
.footer-links { display: flex; gap: 80px; }
.link-col { display: flex; flex-direction: column; gap: 16px; }
.link-col span { font-size: 13px; font-weight: 600; opacity: 0.4; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 8px;}
.link-col a { text-decoration: none; font-size: 14px; opacity: 0.7; transition: opacity 0.3s; }
.link-col a:hover { opacity: 1; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 40px; display: flex; justify-content: space-between; font-size: 13px; opacity: 0.5; }
.footer-bottom a { text-decoration: none; }

/* -------------------------------------
   ANIMATIONS (Scroll Reveal)
   ------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger reveals for elements inside a grid or list */
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
