/* ============================================
   Northline Barber Studio — Custom Styles
   ============================================ */

/* --- Base & Reset Overrides --- */
:root {
  --bg-dark: hsl(220, 10%, 5%);
  --bg-card: hsl(220, 10%, 8%);
  --accent-copper: #C67C4E;
  --accent-copper-light: #d4935f;
  --accent-steel: hsl(220, 8%, 45%);
  --text-primary: hsla(0, 0%, 95%, 1);
  --text-secondary: hsla(0, 0%, 95%, 0.8);
  --text-muted: hsla(0, 0%, 95%, 0.6);
  --text-faint: hsla(0, 0%, 95%, 0.35);
  --glass-bg: hsla(0, 0%, 100%, 0.04);
  --glass-border: hsla(0, 0%, 100%, 0.08);
  --glass-border-top: hsla(0, 0%, 100%, 0.12);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  background: var(--bg-dark);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html.lenis, html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

body {
  font-family: 'Space Grotesk', sans-serif;
  background: var(--bg-dark);
  overflow-x: hidden;
}

/* --- Noise / Grain Overlay --- */
.grain-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* --- Typography --- */
.font-syne {
  font-family: 'Syne', sans-serif;
}

.hero-headline {
  font-size: clamp(5rem, 18vw, 180px);
  font-weight: 300;
  line-height: 0.9;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, hsla(0, 0%, 95%, 1) 30%, var(--accent-copper) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-copper {
  background: linear-gradient(135deg, hsla(0, 0%, 95%, 1) 30%, var(--accent-copper) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Navbar --- */
.navbar {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: hsla(220, 10%, 5%, 0.6);
  border-bottom: 1px solid var(--glass-border);
}

.nav-link {
  position: relative;
  color: var(--text-secondary);
  transition: color 0.3s ease;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent-copper);
  transition: width 0.3s ease;
}

.nav-link:hover {
  color: var(--text-primary);
}

.nav-link:hover::after {
  width: 100%;
}

/* --- Glass Card --- */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-top-color: var(--glass-border-top);
  box-shadow: inset 0 1px 0 0 hsla(0, 0%, 100%, 0.05);
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              border-color 0.4s ease,
              box-shadow 0.4s ease;
}

.glass-card:hover {
  transform: translateY(-4px);
  border-color: hsla(0, 0%, 100%, 0.12);
  box-shadow: inset 0 1px 0 0 hsla(0, 0%, 100%, 0.08),
              0 8px 32px hsla(0, 0%, 0%, 0.3);
}

/* --- CTA Button --- */
.btn-primary {
  background: var(--accent-copper);
  color: var(--bg-dark);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 14px 32px;
  border-radius: 4px;
  transition: background 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  display: inline-block;
  text-decoration: none;
  cursor: pointer;
  border: none;
}

.btn-primary:hover {
  background: var(--accent-copper-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 24px hsla(25, 50%, 54%, 0.25);
}

.btn-secondary {
  color: var(--text-secondary);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 14px 32px;
  border: 1px solid var(--glass-border);
  border-radius: 4px;
  transition: color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
  display: inline-block;
  text-decoration: none;
  cursor: pointer;
  background: transparent;
}

.btn-secondary:hover {
  color: var(--text-primary);
  border-color: var(--accent-copper);
  transform: translateY(-2px);
}

/* --- Hero Background --- */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    hsla(220, 10%, 5%, 0.65) 0%,
    hsla(220, 10%, 5%, 0.5) 40%,
    hsla(220, 10%, 5%, 0.85) 80%,
    hsl(220, 10%, 5%) 100%
  );
}

/* --- Ambient Glow --- */
.ambient-glow {
  position: absolute;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, hsla(25, 50%, 54%, 0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  filter: blur(60px);
}

/* --- Section Spacing --- */
.section-pad {
  padding: 120px 0;
}

@media (max-width: 768px) {
  .section-pad {
    padding: 80px 0;
  }
}

/* --- Statement Section --- */
.statement-line {
  font-size: clamp(2rem, 5vw, 4.5rem);
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* --- Lookbook Grid --- */
.lookbook-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  gap: 16px;
}

.lookbook-grid .look-item:nth-child(1) {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
}

.lookbook-grid .look-item:nth-child(2) {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
}

.lookbook-grid .look-item:nth-child(3) {
  grid-column: 3 / 4;
  grid-row: 1 / 2;
}

.lookbook-grid .look-item:nth-child(4) {
  grid-column: 2 / 4;
  grid-row: 2 / 3;
}

@media (max-width: 768px) {
  .lookbook-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  .lookbook-grid .look-item:nth-child(1) {
    grid-column: 1 / 3;
    grid-row: auto;
  }
  .lookbook-grid .look-item:nth-child(2),
  .lookbook-grid .look-item:nth-child(3) {
    grid-column: auto;
    grid-row: auto;
  }
  .lookbook-grid .look-item:nth-child(4) {
    grid-column: 1 / 3;
    grid-row: auto;
  }
}

.look-item {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  min-height: 280px;
}

.look-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.look-item:hover img {
  transform: scale(1.04);
}

.look-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, hsla(220, 10%, 5%, 0.6) 0%, transparent 50%);
  pointer-events: none;
}

/* --- Craft Section --- */
.craft-section {
  position: relative;
  overflow: hidden;
}

.craft-image {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.craft-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.craft-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    hsl(220, 10%, 5%) 0%,
    hsla(220, 10%, 5%, 0.7) 50%,
    hsla(220, 10%, 5%, 0.4) 100%
  );
}

@media (max-width: 768px) {
  .craft-image::after {
    background: hsla(220, 10%, 5%, 0.75);
  }
}

/* --- Pricing Card --- */
.pricing-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-top-color: var(--glass-border-top);
  box-shadow: inset 0 1px 0 0 hsla(0, 0%, 100%, 0.05);
  border-radius: 8px;
  padding: 40px 32px;
  transition: border-color 0.3s ease;
}

.pricing-card:hover {
  border-color: hsla(0, 0%, 100%, 0.12);
}

.pricing-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 14px 0;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.06);
}

.pricing-item:last-child {
  border-bottom: none;
}

/* --- Testimonial --- */
.testimonial-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-top-color: var(--glass-border-top);
  box-shadow: inset 0 1px 0 0 hsla(0, 0%, 100%, 0.05);
  border-radius: 8px;
  padding: 36px 32px;
}

/* --- Counter --- */
.counter-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: hsla(0, 0%, 100%, 0.04);
  border: 1px solid hsla(0, 0%, 100%, 0.06);
  border-radius: 100px;
  padding: 8px 20px;
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

.counter-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-copper);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

/* --- Final CTA --- */
.final-cta-bg {
  background: radial-gradient(ellipse at center bottom, hsla(25, 50%, 54%, 0.06) 0%, transparent 60%);
}

/* --- Step connector --- */
.step-connector {
  width: 60px;
  height: 1px;
  background: linear-gradient(to right, var(--glass-border), var(--accent-copper), var(--glass-border));
}

@media (max-width: 768px) {
  .step-connector {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--glass-border), var(--accent-copper), var(--glass-border));
  }
}

/* --- Mobile nav --- */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: hsla(220, 10%, 5%, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.mobile-nav.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav a {
  font-size: 1.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: color 0.3s ease;
}

.mobile-nav a:hover {
  color: var(--accent-copper);
}

/* --- Hamburger --- */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  z-index: 100;
  background: none;
  border: none;
  padding: 4px;
}

.hamburger span {
  width: 24px;
  height: 1.5px;
  background: var(--text-primary);
  transition: transform 0.3s ease, opacity 0.3s ease;
  display: block;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }
}

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .counter-dot {
    animation: none;
  }
}
