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

:root {
  --bg: #0e0e0e;
  --bg-mid: #161616;
  --text: #f0f0f0;
  --text-muted: #999;
  --accent: #e8ff00;
  --max-width: 1500px;
  --gutter: 4vw;
  --header-h: 72px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }

/* ===== HEADER ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 var(--gutter);
  background: rgba(14,14,14,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.site-header .logo {
  flex: 0 0 auto;
  margin-right: auto;
}

.site-header .logo img {
  height: 36px;
  width: auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.main-nav a {
  opacity: 0.85;
  transition: opacity 0.2s;
}
.main-nav a:hover { opacity: 1; }

/* Dropdown */
.nav-dropdown {
  position: relative;
}
.nav-dropdown > a::after {
  content: ' ▾';
  font-size: 0.65em;
  opacity: 0.6;
}
.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(20,20,20,0.95);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 4px;
  min-width: 180px;
  padding: 8px 0;
  list-style: none;
}
.nav-dropdown:hover .dropdown-menu { display: block; }
.dropdown-menu li a {
  display: block;
  padding: 10px 20px;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  transition: background 0.15s;
}
.dropdown-menu li a:hover { background: rgba(255,255,255,0.07); }

/* Social icons in nav */
.nav-social {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-left: auto;
}
.nav-social a {
  display: flex;
  align-items: center;
  opacity: 0.7;
  transition: opacity 0.2s;
}
.nav-social a:hover { opacity: 1; }
.nav-social svg { width: 18px; height: 18px; fill: currentColor; }

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  padding: 4px;
}
.menu-toggle svg { width: 24px; height: 24px; fill: currentColor; }

/* ===== PAGE BODY OFFSET ===== */
.page-content {
  padding-top: var(--header-h);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  width: 100%;
  height: calc(100vh - var(--header-h));
  min-height: 480px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transform: scale(1.04);
  transition: transform 8s ease-out;
}
.hero:hover .hero-bg { transform: scale(1); }

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.55) 100%);
}

.hero-text {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 var(--gutter);
  max-width: 800px;
  animation: fadeUp 0.9s 0.3s both;
}

.hero-label {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.7;
  margin-bottom: 1rem;
}

.hero-tagline {
  font-size: clamp(1.6rem, 4vw, 3.2rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* ===== SECTIONS ===== */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 80px var(--gutter);
}

.section-header {
  margin-bottom: 48px;
}

.section-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* ===== PORTFOLIO GRID ===== */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.portfolio-card {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  background: var(--bg-mid);
  aspect-ratio: 4/3;
  display: flex;
  align-items: flex-end;
}

.portfolio-card.featured {
  grid-column: span 2;
  aspect-ratio: 16/9;
}

.portfolio-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, opacity 0.4s ease;
}

.portfolio-card:hover img {
  transform: scale(1.04);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 50%);
  pointer-events: none;
}

.card-info {
  position: relative;
  z-index: 2;
  padding: 20px 24px;
  width: 100%;
}

.card-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}

.card-subtitle {
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.65);
  margin-bottom: 10px;
}

.card-cta {
  display: inline-block;
  padding: 7px 18px;
  border: 1.5px solid rgba(255,255,255,0.7);
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background 0.2s, border-color 0.2s;
}

.card-cta:hover {
  background: rgba(255,255,255,0.15);
  border-color: white;
}

/* ===== ABOUT BANNER ===== */
.about-banner {
  background: var(--bg-mid);
  border-top: 1px solid rgba(255,255,255,0.07);
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.about-banner .section {
  display: flex;
  align-items: center;
  gap: 60px;
  padding-top: 60px;
  padding-bottom: 60px;
}

.about-image {
  flex: 0 0 42%;
  border-radius: 6px;
  overflow: hidden;
}

.about-image img {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

.about-text { flex: 1; }

.about-text p {
  font-size: clamp(1rem, 1.8vw, 1.25rem);
  line-height: 1.75;
  color: #ccc;
}

/* ===== PROJECT PAGE ===== */
.project-hero {
  width: 100%;
  max-height: 65vh;
  overflow: hidden;
  position: relative;
}

.project-hero img {
  width: 100%;
  height: 65vh;
  object-fit: cover;
  object-position: center top;
}

.project-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(14,14,14,0.9) 100%);
}

.project-body {
  max-width: 900px;
  margin: 0 auto;
  padding: 60px var(--gutter) 80px;
}

.project-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.project-subtitle {
  font-size: clamp(1rem, 2vw, 1.3rem);
  color: #bbb;
  margin-bottom: 48px;
  line-height: 1.5;
}

.project-section {
  margin-bottom: 56px;
}

.project-section h2 {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 20px;
  color: var(--accent);
}

.project-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.project-section ul li {
  padding-left: 20px;
  position: relative;
  color: #ccc;
  line-height: 1.6;
}

.project-section ul li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.85em;
}

.project-image-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 40px 0;
}

.project-image-grid img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 4px;
}

.project-image-grid.two-col {
  grid-template-columns: repeat(2, 1fr);
}

.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 40px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.btn-primary {
  background: var(--accent);
  color: #000;
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1.5px solid rgba(255,255,255,0.4);
}
.btn-secondary:hover { border-color: rgba(255,255,255,0.8); }

/* ===== FOOTER ===== */
.site-footer {
  margin-top: 80px;
  position: relative;
  overflow: hidden;
}

.footer-banner {
  width: 100%;
  height: 300px;
  object-fit: cover;
  opacity: 0.4;
  filter: grayscale(20%);
}

.footer-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(14,14,14,0.3) 0%, rgba(14,14,14,0.95) 100%);
}

.footer-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.footer-logo img {
  height: 32px;
  opacity: 0.8;
}

.footer-social {
  display: flex;
  gap: 20px;
}
.footer-social a {
  opacity: 0.6;
  transition: opacity 0.2s;
}
.footer-social a:hover { opacity: 1; }
.footer-social svg { width: 20px; height: 20px; fill: currentColor; }

.footer-links {
  display: flex;
  gap: 24px;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #888;
}
.footer-links a:hover { color: #ddd; }

/* ===== PAGE: TERMS ===== */
.terms-body {
  max-width: 760px;
  margin: 0 auto;
  padding: 80px var(--gutter) 120px;
}

.terms-body h1 {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 40px;
}

.terms-body h2 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 32px 0 12px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.terms-body p {
  color: #bbb;
  margin-bottom: 16px;
  line-height: 1.75;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeUp 0.9s 0.6s both;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .portfolio-grid {
    grid-template-columns: 1fr 1fr;
  }
  .portfolio-card.featured {
    grid-column: span 2;
  }
  .about-banner .section {
    flex-direction: column;
    gap: 32px;
  }
  .about-image {
    flex: none;
    width: 100%;
  }
  .about-image img { height: 260px; }
  .project-image-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  :root { --header-h: 60px; }

  .main-nav { display: none; }
  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 60px; left: 0; right: 0; bottom: 0;
    background: rgba(14,14,14,0.97);
    backdrop-filter: blur(16px);
    padding: 40px var(--gutter);
    gap: 1.5rem;
    font-size: 1.1rem;
    overflow-y: auto;
    z-index: 99;
    align-items: flex-start;
  }
  .menu-toggle { display: flex; margin-left: auto; }
  .nav-dropdown:hover .dropdown-menu { display: none; }
  .nav-dropdown.open .dropdown-menu {
    display: block;
    position: static;
    transform: none;
    background: transparent;
    border: none;
    padding: 8px 0 0 16px;
  }
  .portfolio-grid {
    grid-template-columns: 1fr;
  }
  .portfolio-card.featured { grid-column: span 1; }
  .project-image-grid { grid-template-columns: 1fr; }
  .cta-buttons { flex-direction: column; }
}
