/*
Theme Name: Archmod Premium
Theme URI: 
Author: Archmod
Author URI: 
Description: A premium, modern portfolio theme for Archmod Engineering.
Version: 1.0
License: Proprietary
Text Domain: archmod
*/

/* =========================================
   DESIGN TOKENS
   ========================================= */
:root {
  /* Colors — Off-White Accent System */
  --bg-primary: #0a0a0a;
  --bg-secondary: #111111;
  --text-primary: #f4f4f5;
  --text-secondary: #a1a1aa;
  --accent-color: #f5f5f0;      /* Off-White (replaces gold) */
  --accent-hover: #e8e8e0;      /* Slightly warm off-white hover */
  --header-bg: #f8f8f5;         /* Off-White header */
  --header-text: #1a1a1a;       /* Dark text on light header */
  --footer-bg: #f5f5f0;         /* Off-White footer */
  --footer-text: #4a4a4a;       /* Dark text for footer */
  --footer-border: rgba(0,0,0,0.08);

  /* Typography Scale */
  --font-primary: 'Inter', sans-serif;
  --font-heading: 'Outfit', sans-serif;

  /* Font Sizes — clamp(min, fluid, max) */
  --fs-xs:   clamp(0.70rem, 1.2vw, 0.75rem);   /* 11–12px */
  --fs-sm:   clamp(0.80rem, 1.5vw, 0.875rem);  /* 13–14px */
  --fs-base: clamp(0.9375rem, 1.8vw, 1rem);    /* 15–16px */
  --fs-md:   clamp(1rem, 2vw, 1.125rem);       /* 16–18px */
  --fs-lg:   clamp(1.125rem, 2.5vw, 1.25rem);  /* 18–20px */
  --fs-xl:   clamp(1.25rem, 3vw, 1.5rem);      /* 20–24px */
  --fs-2xl:  clamp(1.5rem, 4vw, 2rem);         /* 24–32px */
  --fs-3xl:  clamp(1.75rem, 5vw, 2.5rem);      /* 28–40px */
  --fs-4xl:  clamp(2rem, 6vw, 3.5rem);         /* 32–56px */
  --fs-hero: clamp(2.25rem, 7vw, 5rem);        /* 36–80px */

  /* Line Heights */
  --lh-tight:  1.2;
  --lh-snug:   1.35;
  --lh-normal: 1.6;
  --lh-loose:  1.8;

  /* Letter Spacing */
  --ls-tight:  -0.02em;
  --ls-normal:  0;
  --ls-wide:    0.05em;
  --ls-wider:   0.08em;
  --ls-widest:  0.12em;

  /* Spacing (8px system) */
  --spacing-1: 0.5rem;    /* 8px  */
  --spacing-2: 1rem;      /* 16px */
  --spacing-3: 1.5rem;    /* 24px */
  --spacing-4: 2rem;      /* 32px */
  --spacing-5: 2.5rem;    /* 40px */
  --spacing-6: 3rem;      /* 48px */
  --spacing-8: 4rem;      /* 64px */
  --spacing-12: 6rem;     /* 96px */
  --spacing-16: 8rem;     /* 128px */

  /* Borders */
  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   16px;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast:   0.15s ease-in-out;
  --transition-normal: 0.3s ease-in-out;
  --transition-slow:   0.5s ease-in-out;
}

/* =========================================
   RESET & BASE
   ========================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 100%; /* Never zoom — let clamp() handle scaling */
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  color: var(--text-primary);
  background: radial-gradient(circle at 15% 50%, rgba(245,245,240,0.03), transparent 40%),
              radial-gradient(circle at 85% 30%, rgba(245,245,240,0.03), transparent 40%),
              #0a0a0a;
  background-color: var(--bg-primary);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: 80px; /* Accounts for fixed header */
  overflow-x: hidden;
}

/* =========================================
   TYPOGRAPHY SYSTEM
   ========================================= */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  margin-bottom: var(--spacing-2);
  color: inherit;
}

h1 { font-size: var(--fs-4xl); }
h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-2xl); }
h4 { font-size: var(--fs-xl); }
h5 { font-size: var(--fs-lg); }
h6 { font-size: var(--fs-md); }

p {
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  margin-bottom: 0;
}

small, .text-sm { font-size: var(--fs-sm); }
.text-xs        { font-size: var(--fs-xs); }

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-normal);
}

a:hover {
  color: var(--accent-color);
}

ul, ol {
  padding-left: var(--spacing-3);
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

/* =========================================
   LAYOUT UTILITIES
   ========================================= */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--spacing-3);
}

@media (min-width: 768px) {
  .container {
    padding: 0 var(--spacing-4);
  }
}

.section {
  padding: var(--spacing-12) 0;
}

@media (max-width: 768px) {
  .section {
    padding: var(--spacing-8) 0;
  }
}

/* =========================================
   HEADER — Off-White
   ========================================= */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: var(--spacing-2) 0;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
  transition: box-shadow var(--transition-normal);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-3);
}

.site-title {
  font-size: var(--fs-xl);
  font-weight: 700;
  letter-spacing: var(--ls-wider);
  color: var(--header-text);
}

/* Desktop Nav */
.site-nav ul {
  display: flex;
  list-style: none;
  gap: var(--spacing-4);
}

.site-nav a {
  font-size: var(--fs-sm);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  color: var(--header-text);
  position: relative;
  padding-bottom: 2px;
}

.site-nav a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--header-text);
  border-radius: 2px;
  transition: width var(--transition-normal);
}

.site-nav a:hover::after,
.site-nav a.active::after {
  width: 100%;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--header-text);
}

/* Header Buttons */
.header-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--header-text);
  color: var(--header-text);
  background: transparent;
  transition: all var(--transition-normal);
  white-space: nowrap;
}

.header-btn:hover {
  background: var(--header-text);
  color: var(--header-bg);
}

.header-btn-filled {
  background: var(--header-text);
  color: var(--header-bg);
}

.header-btn-filled:hover {
  background: transparent;
  color: var(--header-text);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  z-index: 200;
  flex-shrink: 0;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--header-text);
  border-radius: 2px;
  transition: all 0.35s cubic-bezier(0.4,0,0.2,1);
  transform-origin: center;
}

.hamburger.open span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.hamburger.open span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Nav Overlay */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--header-bg);
  z-index: 150;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  padding: var(--spacing-6);
}

.mobile-nav.open {
  opacity: 1;
  pointer-events: all;
}

.mobile-nav a {
  font-family: var(--font-heading);
  font-size: var(--fs-3xl);
  font-weight: 300;
  color: var(--header-text);
  letter-spacing: var(--ls-tight);
  text-align: center;
  transition: all var(--transition-normal);
}

.mobile-nav a:hover {
  color: #666;
}

.mobile-nav-actions {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-2);
  width: 100%;
  max-width: 280px;
  margin-top: var(--spacing-4);
}

.mobile-nav-actions .header-btn {
  width: 100%;
  justify-content: center;
  font-size: var(--fs-sm);
  padding: 12px 20px;
}

/* =========================================
   BUTTONS
   ========================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0.75em 1.75em;
  border-radius: var(--radius-full);
  font-family: var(--font-primary);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition-normal);
  border: 1.5px solid transparent;
  white-space: nowrap;
  text-decoration: none;
  line-height: 1;
}

.btn-primary {
  background-color: var(--accent-color);
  color: #1a1a1a;
  border-color: var(--accent-color);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  color: #1a1a1a;
  border-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(245,245,240,0.2);
}

.btn-outline {
  background: transparent;
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.btn-outline:hover {
  background: var(--accent-color);
  color: #1a1a1a;
  transform: translateY(-2px);
}

@media (max-width: 480px) {
  .btn {
    width: 100%;
    padding: 0.85em 1.5em;
  }
}

/* Submit button */
.btn-submit {
  width: 100%;
  padding: 1em;
  background: #1a1a1a;
  color: #fff;
  border: none;
  font-family: var(--font-primary);
  font-size: var(--fs-base);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-normal);
  margin-top: var(--spacing-2);
}

.btn-submit:hover {
  background: #333;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* =========================================
   CARDS
   ========================================= */
.card {
  background-color: var(--bg-secondary);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: var(--radius-lg);
  padding: var(--spacing-4);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  border-color: rgba(255,255,255,0.1);
}

/* =========================================
   HERO SECTION
   ========================================= */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
}

.hero-title {
  font-size: var(--fs-hero);
  letter-spacing: var(--ls-tight);
  line-height: var(--lh-tight);
  margin-bottom: var(--spacing-4);
  background: linear-gradient(to right, #fff, #a1a1aa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: var(--fs-lg);
  line-height: var(--lh-loose);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-6);
  max-width: 600px;
  /* removed white-space: nowrap — allow wrapping on mobile */
}

/* =========================================
   MASONRY PROJECTS GRID (Homepage)
   ========================================= */
.masonry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  grid-auto-rows: 250px;
  gap: var(--spacing-4);
}

@media (max-width: 600px) {
  .masonry-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 200px;
    gap: var(--spacing-2);
  }
}

.masonry-grid .project-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.03);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (min-width: 768px) {
  .masonry-grid .grid-span-2 {
    grid-column: span 2;
    grid-row: span 2;
  }
  .masonry-grid .grid-span-row {
    grid-row: span 2;
  }
}

.masonry-grid .project-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 50px rgba(245,245,240,0.12);
  border-color: rgba(245,245,240,0.15);
  z-index: 2;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-card:hover .project-image {
  transform: scale(1.1);
}

/* Overlay */
.project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,10,10,0.95) 0%, rgba(10,10,10,0.4) 40%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--spacing-4);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-overlay {
  background: linear-gradient(to top, rgba(10,10,10,0.98) 0%, rgba(10,10,10,0.6) 50%, rgba(0,0,0,0.2) 100%);
}

.project-overlay h3 {
  font-size: var(--fs-xl);
  color: #fff;
  margin-bottom: var(--spacing-1);
  text-shadow: 0 2px 10px rgba(0,0,0,0.8);
  transition: all 0.3s ease;
}

.project-overlay p {
  font-size: var(--fs-sm);
  color: var(--accent-color);
  font-weight: 500;
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.project-card:hover .project-overlay h3 {
  color: var(--accent-color);
}
.project-card:hover .project-overlay p {
  color: #fff;
}

/* =========================================
   PROJECT SHOWCASE — Archive Page
   ========================================= */
.showcase-container {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-8);
  margin-top: var(--spacing-4);
}

.project-showcase {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16,1,0.3,1), box-shadow 0.4s cubic-bezier(0.16,1,0.3,1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transform: translateY(30px);
}

.project-showcase.visible {
  opacity: 1;
  transform: translateY(0);
}

.project-showcase:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.12), 0 0 0 1px rgba(0,0,0,0.06);
}

/* Showcase Image / Slider */
.showcase-image-wrapper {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .showcase-image-wrapper {
    min-height: 360px;
  }
}

.showcase-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.16,1,0.3,1);
  display: block;
}

.project-showcase:hover .showcase-image-wrapper img {
  transform: scale(1.04);
}

/* Showcase Content */
.showcase-content {
  flex: 1;
  padding: var(--spacing-4) var(--spacing-4);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #fff;
}

@media (min-width: 768px) {
  .showcase-content {
    padding: var(--spacing-6) var(--spacing-6);
  }
}

.showcase-category {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  color: #888;
  margin-bottom: var(--spacing-2);
}

.showcase-title {
  font-size: var(--fs-3xl);
  font-weight: 300;
  line-height: var(--lh-snug);
  margin-bottom: var(--spacing-2);
  color: #111;
  letter-spacing: var(--ls-tight);
}

@media (max-width: 480px) {
  .showcase-title {
    font-size: var(--fs-2xl);
  }
}

.showcase-client {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #555;
  font-size: var(--fs-sm);
  font-weight: 500;
  margin-bottom: var(--spacing-3);
}

.showcase-description {
  font-size: var(--fs-base);
  color: #444;
  line-height: var(--lh-loose);
  margin-bottom: var(--spacing-4);
}

.showcase-scope-title {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: #1a1a1a;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  margin-bottom: var(--spacing-2);
}

.showcase-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: var(--spacing-4);
}

.showcase-tag {
  border: 1px solid #ccc;
  color: #444;
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: var(--ls-wide);
}

.showcase-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--spacing-2);
  margin-top: auto;
  padding-top: var(--spacing-3);
  border-top: 1px solid #eee;
}

.showcase-area {
  font-size: var(--fs-sm);
  color: #666;
  letter-spacing: var(--ls-wide);
}

.showcase-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #111;
  color: #fff;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: var(--ls-wide);
  text-decoration: none;
  transition: all var(--transition-normal);
}

.showcase-btn:hover {
  background: #333;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

/* Showcase Status */
.showcase-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #6b7280;
  background: #f3f4f6;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: var(--ls-wide);
  margin-bottom: var(--spacing-2);
  align-self: flex-start;
}

/* Showcase Badges */
.showcase-badge {
  position: absolute;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  z-index: 12;
}

.showcase-badge.top-left {
  top: 16px;
  left: 16px;
  background: rgba(26,26,26,0.85);
  color: #fff;
  backdrop-filter: blur(4px);
}

.showcase-badge.bottom-left {
  bottom: 16px;
  left: 16px;
  background: rgba(26,26,26,0.85);
  color: #fff;
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* =========================================
   IMAGE SLIDER (Archive + Single Project)
   ========================================= */
.showcase-slider {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 100%;
  min-height: 280px;
}

.slider-images {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.slider-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.9);
  color: #1a1a1a;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all var(--transition-normal);
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Always visible on touch devices */
@media (hover: none) {
  .slider-btn {
    opacity: 1;
    background: rgba(255,255,255,0.85);
  }
}

.showcase-slider:hover .slider-btn,
.showcase-image-wrapper:hover .slider-btn {
  opacity: 1;
}

.slider-btn:hover {
  background: #1a1a1a;
  color: #fff;
  transform: translateY(-50%) scale(1.1);
}

.slider-btn.prev-btn { left: 10px; }
.slider-btn.next-btn { right: 10px; }

.slider-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 7px;
  z-index: 10;
}

.slider-dots .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  padding: 0;
}

.slider-dots .dot.active {
  background: #fff;
  transform: scale(1.3);
}

/* =========================================
   SCROLL ANIMATIONS
   ========================================= */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(28px);
  transition: all 0.8s cubic-bezier(0.16,1,0.3,1);
}

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes revealUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================
   FOOTER — Off-White
   ========================================= */
.contact-section {
  background-color: var(--footer-bg) !important;
  border-top: 1px solid var(--footer-border) !important;
}

.contact-section h2 {
  color: #111 !important;
}

.contact-section h4 {
  color: #1a1a1a !important;
}

.contact-section p,
.contact-section span {
  color: var(--footer-text) !important;
}

.contact-section .btn-primary {
  background: #1a1a1a;
  color: #fff;
  border-color: #1a1a1a;
}

.contact-section .btn-primary:hover {
  background: #333;
  border-color: #333;
  color: #fff;
}

/* Footer Glow Hover on Links */
.contact-section a {
  color: var(--footer-text) !important;
  transition: all var(--transition-normal);
  position: relative;
}

.contact-section a:not(.btn-primary):hover {
  color: #111 !important;
  text-shadow: 0 0 12px rgba(0,0,0,0.15);
}

.site-footer {
  background: var(--footer-bg) !important;
  border-top: 1px solid var(--footer-border) !important;
  padding: var(--spacing-4) 0;
}

.site-footer p,
.site-footer a {
  color: var(--footer-text) !important;
  font-size: var(--fs-sm);
}

.site-footer a:hover {
  color: #111 !important;
  text-shadow: 0 0 10px rgba(0,0,0,0.12);
}

/* =========================================
   WIREFRAME ANIMATION
   ========================================= */
.hero-art-container {
  perspective: 1000px;
  width: 280px;
  height: 280px;
  margin: 0 auto;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

@media (max-width: 768px) {
  .hero-art-container {
    width: 200px;
    height: 200px;
    transform: none !important;
  }
}

.rotating-wireframe {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  animation: rotate-wireframe 20s linear infinite;
}

.wire-layer {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: 1px solid var(--accent-color);
  background: rgba(245,245,240,0.02);
  box-shadow: 0 0 15px rgba(245,245,240,0.08), inset 0 0 15px rgba(245,245,240,0.08);
}

.layer1 { width: 260px; height: 260px; animation: pulse-z1 4s ease-in-out infinite alternate; }
.layer2 { width: 200px; height: 200px; animation: pulse-z2 4s ease-in-out infinite alternate; }
.layer3 { width: 140px; height: 140px; }
.layer4 { width:  90px; height:  90px; animation: pulse-z4 4s ease-in-out infinite alternate; }
.layer5 { width:  36px; height:  36px; border-radius: 50%; background: var(--accent-color); box-shadow: 0 0 18px rgba(245,245,240,0.4); animation: pulse-z5 4s ease-in-out infinite alternate; }

@keyframes rotate-wireframe {
  0%   { transform: rotateX(60deg) rotateZ(0deg); }
  100% { transform: rotateX(60deg) rotateZ(360deg); }
}

@keyframes pulse-z1 { 0% { transform: translate(-50%,-50%) translateZ(110px); } 100% { transform: translate(-50%,-50%) translateZ(28px); } }
@keyframes pulse-z2 { 0% { transform: translate(-50%,-50%) translateZ(55px); } 100% { transform: translate(-50%,-50%) translateZ(14px); } }
@keyframes pulse-z4 { 0% { transform: translate(-50%,-50%) translateZ(-55px); } 100% { transform: translate(-50%,-50%) translateZ(-14px); } }
@keyframes pulse-z5 { 0% { transform: translate(-50%,-50%) translateZ(-110px); } 100% { transform: translate(-50%,-50%) translateZ(-28px); } }

/* =========================================
   LIGHTBOX
   ========================================= */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
  backdrop-filter: blur(6px);
}

.lightbox.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox img {
  max-width: 92%;
  max-height: 92vh;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 40px rgba(0,0,0,0.8);
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.175,0.885,0.32,1.275);
}

.lightbox.active img {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: var(--spacing-3);
  right: var(--spacing-3);
  color: white;
  font-size: 2rem;
  cursor: pointer;
  z-index: 1001;
  width: 44px;
  height: 44px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  transition: background var(--transition-fast);
}

.lightbox-close:hover {
  background: rgba(255,255,255,0.25);
}

/* =========================================
   SINGLE PROJECT MODAL
   ========================================= */
body.page-modal-mode {
  background: #f5f5f5;
  padding-top: 0;
}

body.page-modal-mode .site-header,
body.page-modal-mode .contact-section,
body.page-modal-mode .site-footer {
  display: none !important;
}

.project-modal-container {
  max-width: 1200px;
  margin: 32px auto;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  overflow: hidden;
  position: relative;
  z-index: 100;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-4) var(--spacing-5);
  border-bottom: 1px solid #eaeaea;
  flex-wrap: wrap;
  gap: var(--spacing-2);
}

.modal-header-left {
  display: flex;
  flex-direction: column;
}

.modal-category {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  color: #888;
  margin-bottom: 4px;
}

.modal-title {
  font-size: var(--fs-3xl);
  font-weight: 400;
  color: #111;
  margin: 0;
  letter-spacing: var(--ls-tight);
}

.modal-header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Print button hidden permanently */
.print-btn {
  display: none !important;
}

.modal-close-btn {
  font-size: 2rem;
  color: #999;
  text-decoration: none;
  line-height: 1;
  transition: color var(--transition-normal);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #f5f5f5;
}

.modal-close-btn:hover {
  color: #111;
  background: #eee;
}

.modal-slider-wrapper {
  width: 100%;
  height: 480px;
  background: #f0f0f0;
  position: relative;
}

@media (max-width: 768px) {
  .modal-slider-wrapper {
    height: 280px;
  }
}

.modal-slider-wrapper .showcase-slider {
  border-radius: 0;
  box-shadow: none;
  height: 100%;
}

.modal-details-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  padding: var(--spacing-4) var(--spacing-5);
  border-bottom: 1px solid #eaeaea;
  background: #fdfdfd;
}

@media (max-width: 768px) {
  .modal-details-grid {
    grid-template-columns: 1fr 1fr;
    padding: var(--spacing-3);
  }
}

@media (max-width: 480px) {
  .modal-details-grid {
    grid-template-columns: 1fr;
  }
  .modal-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

.modal-detail-item {
  display: flex;
  flex-direction: column;
}

.modal-detail-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  color: #999;
  margin-bottom: 6px;
}

.modal-detail-value {
  font-size: var(--fs-base);
  font-weight: 600;
  color: #111;
}

.modal-content-area {
  padding: var(--spacing-5);
}

@media (max-width: 480px) {
  .modal-content-area {
    padding: var(--spacing-3);
  }
}

.modal-concept-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  color: #999;
  margin-bottom: 12px;
  display: block;
}

.modal-concept-text {
  font-size: var(--fs-lg);
  line-height: var(--lh-loose);
  font-weight: 300;
  color: #444;
  margin-bottom: var(--spacing-6);
  max-width: 900px;
}

.modal-scope-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-5);
  border-top: 1px solid #eaeaea;
  padding-top: var(--spacing-4);
}

@media (max-width: 600px) {
  .modal-scope-grid {
    grid-template-columns: 1fr;
    gap: var(--spacing-3);
  }
}

.modal-scope-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.modal-scope-list li {
  font-size: var(--fs-base);
  color: #444;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-scope-list li::before {
  content: '—';
  color: #bbb;
  flex-shrink: 0;
}

.modal-systems-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.modal-system-tag {
  font-size: var(--fs-sm);
  color: #555;
  border: 1px solid #ddd;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.modal-system-tag:hover {
  border-color: #888;
  color: #111;
}

/* =========================================
   ABOUT / EXPERIENCE / CONTACT GRIDS
   ========================================= */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: var(--spacing-8);
  align-items: stretch;
}

.experience-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-5);
  align-items: center;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-8);
  align-items: start;
}

.feature-icons-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-3);
  margin-top: auto;
}

/* =========================================
   CONTACT PAGE
   ========================================= */
.contact-page-section {
  padding-top: 100px;
  padding-bottom: var(--spacing-8);
  background-color: var(--bg-primary);
  min-height: 100vh;
}

.contact-page-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: var(--spacing-8);
}

@media (max-width: 992px) {
  .contact-page-grid {
    grid-template-columns: 1fr;
  }
}

.inquiry-form-container {
  background: #fff;
  border: 1px solid #eaeaea;
  border-radius: var(--radius-lg);
  padding: var(--spacing-5);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.inquiry-form-header {
  margin-bottom: var(--spacing-4);
  border-bottom: 1px solid #eaeaea;
  padding-bottom: var(--spacing-3);
}

.inquiry-form-header h2 {
  color: #111;
  font-size: var(--fs-2xl);
  font-weight: 300;
  margin-bottom: 4px;
  letter-spacing: var(--ls-tight);
}

.inquiry-form-header p {
  color: #888;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  font-weight: 600;
}

.form-group {
  margin-bottom: var(--spacing-3);
}

.form-group label {
  display: block;
  color: #555;
  font-size: var(--fs-xs);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  font-weight: 600;
}

.form-control {
  width: 100%;
  background: #fdfdfd;
  border: 1px solid #ddd;
  color: #111;
  padding: 14px 18px;
  font-size: var(--fs-base);
  font-family: var(--font-primary);
  border-radius: var(--radius-sm);
  transition: all var(--transition-normal);
}

.form-control:focus {
  outline: none;
  border-color: #1a1a1a;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(26,26,26,0.06);
}

.form-control::placeholder {
  color: #bbb;
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%231a1a1a%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-position: right 18px top 50%;
  background-size: 11px auto;
}

.form-row {
  display: flex;
  gap: var(--spacing-2);
}

.form-row .form-group {
  flex: 1;
}

@media (max-width: 480px) {
  .form-row {
    flex-direction: column;
  }
}

/* Discipline Checkboxes */
.discipline-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-top: 8px;
}

.discipline-checkbox { display: none; }

.discipline-label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #fdfdfd;
  border: 1px solid #ddd;
  border-radius: var(--radius-sm);
  color: #555;
  font-size: var(--fs-sm);
  cursor: pointer;
  transition: all var(--transition-normal);
  user-select: none;
}

.discipline-label::before {
  content: '+';
  color: #888;
  font-weight: 700;
  font-size: var(--fs-base);
  line-height: 1;
}

.discipline-label:hover {
  background: #f0f0f0;
  color: #111;
  border-color: #aaa;
}

.discipline-checkbox:checked + .discipline-label {
  background: #1a1a1a;
  color: #fff;
  border-color: #1a1a1a;
}

.discipline-checkbox:checked + .discipline-label::before {
  content: '✓';
  color: #fff;
}

/* =========================================
   PROJECT LAYOUT GRID (Archive)
   ========================================= */
.project-layout-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-4);
  align-items: start;
}

@media (min-width: 992px) {
  .project-layout-grid {
    grid-template-columns: 1fr 1.8fr;
  }
}

/* =========================================
   RESPONSIVE — MOBILE OVERRIDES
   ========================================= */
@media (max-width: 768px) {
  body {
    padding-top: 70px;
  }

  /* Hide desktop nav on mobile */
  .site-nav {
    display: none;
  }

  /* Show hamburger on mobile */
  .hamburger {
    display: flex;
  }

  /* Show mobile nav when open */
  .mobile-nav {
    display: flex;
  }

  /* Hide desktop header buttons on mobile */
  .header-right {
    display: none;
  }

  /* Grids → single column */
  .about-grid,
  .experience-grid,
  .contact-grid,
  .feature-icons-grid {
    grid-template-columns: 1fr !important;
    gap: var(--spacing-4);
  }

  .hero-art-container {
    margin-top: var(--spacing-4);
  }

  /* Contact section grid fix */
  .contact-section [style*="grid-template-columns: 1fr 1fr"] {
    display: flex !important;
    flex-direction: column !important;
    gap: var(--spacing-3) !important;
  }

  /* Footer grid fix */
  .site-footer .container {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: var(--spacing-2) !important;
    text-align: center !important;
  }

  /* Showcase footer wrap */
  .showcase-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .showcase-btn {
    width: 100%;
    justify-content: center;
  }

  /* Hero */
  .hero .container {
    flex-direction: column !important;
  }
}

@media (max-width: 480px) {
  .modal-title {
    font-size: var(--fs-2xl);
  }

  .modal-concept-text {
    font-size: var(--fs-base);
  }

  .project-modal-container {
    margin: 0;
    border-radius: 0;
  }
}
