/* ==========================================================
   Corazon Tattoo – Design System & Styles
   Dark / Gold / Elegant Serif
   ========================================================== */

/* --- CSS Custom Properties (Design Tokens) --- */
:root {
  /* Palette */
  --black:        #0a0a0a;
  --black-light:  #141414;
  --black-card:   #1a1a1a;
  --gold:         #c9a84c;
  --gold-light:   #e2c97e;
  --gold-dark:    #a68a3a;
  --white:        #f5f0e8;
  --white-muted:  #bbb5a7;
  --grey:         #2a2a2a;
  --grey-light:   #3a3a3a;

  /* Typography */
  --font-heading: 'Playfair Display', 'Georgia', serif;
  --font-body:    'Raleway', 'Helvetica Neue', sans-serif;

  /* Spacing */
  --space-xs:  0.5rem;
  --space-sm:  1rem;
  --space-md:  2rem;
  --space-lg:  4rem;
  --space-xl:  6rem;

  /* Misc */
  --radius:     4px;
  --transition: 0.3s ease;
  --max-width:  1200px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-body);
  background: var(--black);
  color: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

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

a:hover {
  color: var(--gold-light);
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--white);
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }

/* --- Utility --- */
.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.section {
  padding: var(--space-xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--space-lg);
}

.section-title h2 {
  display: inline-block;
  position: relative;
  padding-bottom: var(--space-xs);
}

.section-title h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: var(--gold);
}

.section-subtitle {
  color: var(--white-muted);
  font-size: 1.05rem;
  margin-top: var(--space-sm);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.gold {
  color: var(--gold);
}

.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border: 2px solid var(--gold);
  color: var(--gold);
  background: transparent;
  cursor: pointer;
  transition: all var(--transition);
  border-radius: var(--radius);
}

.btn:hover {
  background: var(--gold);
  color: var(--black);
}

.btn--filled {
  background: var(--gold);
  color: var(--black);
}

.btn--filled:hover {
  background: var(--gold-light);
  color: var(--black);
}

/* --- Divider --- */
.divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dark), transparent);
  border: none;
  margin: 0;
}

/* ==========================================================
   NAVIGATION
   ========================================================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: var(--space-sm) 0;
  transition: background var(--transition), padding var(--transition);
  background: transparent;
}

.nav.scrolled {
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(10px);
  padding: 0.6rem 0;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--gold);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.nav__logo span {
  font-weight: 300;
  color: var(--white-muted);
  font-size: 0.75em;
  display: block;
  letter-spacing: 3px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  list-style: none;
}

.nav__links a {
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  position: relative;
  padding-bottom: 4px;
}

.nav__links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width var(--transition);
}

.nav__links a:hover::after {
  width: 100%;
}

.nav__links a:hover {
  color: var(--gold);
}

/* Language toggle */
.lang-toggle {
  background: none;
  border: 1px solid var(--grey-light);
  color: var(--white-muted);
  font-size: 0.75rem;
  padding: 0.3rem 0.7rem;
  cursor: pointer;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: all var(--transition);
  border-radius: var(--radius);
  font-family: var(--font-body);
}

.lang-toggle:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Mobile menu toggle */
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all var(--transition);
}

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

.hero__bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(10, 10, 10, 0.3) 0%,
    rgba(10, 10, 10, 0.7) 60%,
    var(--black) 100%
  ),
  url('images/hero-bg.jpg') center/cover no-repeat;
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  padding: 0 var(--space-md);
}

.hero__tagline {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-sm);
}

.hero h1 {
  margin-bottom: var(--space-sm);
}

.hero__subtitle {
  font-size: 1.15rem;
  color: var(--white-muted);
  margin-bottom: var(--space-md);
  max-width: 550px;
  margin-left: auto;
  margin-right: auto;
}

.hero__cta {
  display: flex;
  gap: var(--space-sm);
  justify-content: center;
  flex-wrap: wrap;
}

/* Scroll indicator */
.hero__scroll {
  position: absolute;
  bottom: var(--space-md);
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--white-muted);
  font-size: 0.7rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  animation: float 2s ease-in-out infinite;
}

.hero__scroll span {
  display: block;
  width: 1px;
  height: 30px;
  background: linear-gradient(to bottom, var(--gold), transparent);
}

@keyframes float {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ==========================================================
   ABOUT PREVIEW
   ========================================================== */
.about-preview {
  background: var(--black-light);
}

.about-preview .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
}

.about-preview__img {
  aspect-ratio: 3/4;
  background: var(--grey);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--grey-light);
}

.about-preview__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-preview__text h2 {
  margin-bottom: var(--space-sm);
}

.about-preview__text p {
  color: var(--white-muted);
  margin-bottom: var(--space-md);
  max-width: 500px;
}

.about-preview__years {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  color: var(--gold);
  font-weight: 700;
  line-height: 1;
  margin-bottom: var(--space-xs);
}

.about-preview__years-label {
  font-size: 0.85rem;
  color: var(--white-muted);
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ==========================================================
   ARTISTS SECTION
   ========================================================== */
.artists {
  background: var(--black);
}

.artists__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-md);
}

.artist-card {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), border-color var(--transition);
}

.artist-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold-dark);
}

.artist-card__img {
  aspect-ratio: 4/3;
  background: var(--grey);
  overflow: hidden;
}

.artist-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}

.artist-card:hover .artist-card__img img {
  transform: scale(1.05);
}

.artist-card__body {
  padding: var(--space-md);
}

.artist-card__name {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin-bottom: var(--space-xs);
}

.artist-card__role {
  color: var(--gold);
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.artist-card__desc {
  color: var(--white-muted);
  font-size: 0.95rem;
}

/* ==========================================================
   PORTFOLIO / GALLERY
   ========================================================== */
.portfolio {
  background: var(--black-light);
}

.portfolio__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-sm);
}

.portfolio__item {
  aspect-ratio: 1;
  background: var(--grey);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  cursor: pointer;
}

.portfolio__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.portfolio__item:hover img {
  transform: scale(1.08);
}

.portfolio__item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,10,10,0.6) 0%, transparent 50%);
  opacity: 0;
  transition: opacity var(--transition);
}

.portfolio__item:hover::after {
  opacity: 1;
}

/* ==========================================================
   SERVICES
   ========================================================== */
.services {
  background: var(--black);
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-md);
}

.service-card {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-md);
  text-align: center;
  transition: border-color var(--transition), transform var(--transition);
}

.service-card:hover {
  border-color: var(--gold-dark);
  transform: translateY(-4px);
}

.service-card__icon {
  font-size: 2.5rem;
  margin-bottom: var(--space-sm);
  color: var(--gold);
}

.service-card h3 {
  margin-bottom: var(--space-xs);
}

.service-card p {
  color: var(--white-muted);
  font-size: 0.95rem;
  margin-bottom: var(--space-sm);
}

.service-card .badge {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  font-size: 0.7rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border: 1px solid var(--gold-dark);
  color: var(--gold);
  border-radius: 20px;
}

/* ==========================================================
   FOOTER
   ========================================================== */
.footer {
  background: var(--black-light);
  border-top: 1px solid var(--grey);
  padding: var(--space-lg) 0 var(--space-md);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.footer__brand {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  color: var(--gold);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.footer__desc {
  color: var(--white-muted);
  font-size: 0.9rem;
  max-width: 350px;
}

.footer h4 {
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-sm);
}

.footer__links {
  list-style: none;
}

.footer__links li {
  margin-bottom: 0.5rem;
}

.footer__links a {
  color: var(--white-muted);
  font-size: 0.9rem;
}

.footer__links a:hover {
  color: var(--gold);
}

.footer__contact p {
  color: var(--white-muted);
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}

.footer__contact a {
  color: var(--white-muted);
}

.footer__social {
  display: flex;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
}

.footer__social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--grey-light);
  border-radius: 50%;
  color: var(--white-muted);
  font-size: 1rem;
  transition: all var(--transition);
}

.footer__social a:hover {
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
}

.footer__bottom {
  text-align: center;
  padding-top: var(--space-md);
  border-top: 1px solid var(--grey);
  color: var(--white-muted);
  font-size: 0.8rem;
}

/* ==========================================================
   MOBILE RESPONSIVE
   ========================================================== */
@media (max-width: 768px) {
  .nav__links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%;
    max-width: 320px;
    height: 100vh;
    background: var(--black-light);
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem var(--space-md) var(--space-md);
    gap: var(--space-sm);
    transition: right var(--transition);
    border-left: 1px solid var(--grey);
  }

  .nav__links.open {
    right: 0;
  }

  .nav__burger {
    display: flex;
    z-index: 1001;
  }

  .nav__burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

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

  .nav__burger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .about-preview .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-preview__img {
    max-width: 400px;
    margin: 0 auto;
  }

  .about-preview__text p {
    max-width: 100%;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer__desc {
    max-width: 100%;
    margin: 0 auto;
  }

  .footer__social {
    justify-content: center;
  }

  .hero__cta {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .portfolio__grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xs);
  }
}

/* --- Overlay for mobile menu --- */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}

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

/* ==========================================================
   ADMIN PAGES
   ========================================================== */

/* Nav actions */
.admin-nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.admin-user-email {
  color: var(--white-muted);
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}

/* Login */
.admin-login {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 80px;
}

.admin-login__card {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-lg) var(--space-md);
  max-width: 420px;
  width: 100%;
  text-align: center;
}

.admin-login__card h2 {
  margin-bottom: var(--space-xs);
}

.admin-login__sub {
  color: var(--white-muted);
  font-size: 0.95rem;
  margin-bottom: var(--space-md);
}

.admin-form .form-group {
  margin-bottom: var(--space-sm);
  text-align: left;
}

.admin-form label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white-muted);
  margin-bottom: 0.3rem;
}

.admin-form input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--black);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color var(--transition);
}

.admin-form input:focus {
  outline: none;
  border-color: var(--gold);
}

.admin-error {
  color: #e74c3c;
  font-size: 0.85rem;
  min-height: 1.2em;
  margin-bottom: var(--space-xs);
}

.btn--full {
  width: 100%;
  text-align: center;
}

.btn--sm {
  padding: 0.45rem 1.2rem;
  font-size: 0.75rem;
}

/* Dashboard */
.admin-dashboard {
  padding-top: 100px;
}

.admin-stats {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.admin-stat {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-sm) var(--space-md);
  text-align: center;
  flex: 1;
}

.admin-stat__num {
  display: block;
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--gold);
  font-weight: 700;
  line-height: 1.2;
}

.admin-stat__label {
  font-size: 0.75rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--white-muted);
}

/* Controls */
.admin-controls {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
}

.admin-search,
.admin-filter {
  padding: 0.6rem 1rem;
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: border-color var(--transition);
}

.admin-search {
  flex: 1;
  min-width: 200px;
}

.admin-search:focus,
.admin-filter:focus {
  outline: none;
  border-color: var(--gold);
}

.admin-filter option {
  background: var(--black-card);
  color: var(--white);
}

/* Table */
.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-table th {
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold);
  padding: 0.8rem 0.6rem;
  border-bottom: 1px solid var(--grey-light);
  white-space: nowrap;
}

.admin-table td {
  padding: 0.7rem 0.6rem;
  border-bottom: 1px solid var(--grey);
  color: var(--white-muted);
  vertical-align: middle;
}

.admin-table tr:hover td {
  background: rgba(201, 168, 76, 0.04);
}

.flagged-row td {
  border-left: 3px solid var(--gold);
}

.flag-cell {
  color: var(--gold);
  font-size: 1.1rem;
  text-align: center;
}

.btn--view {
  padding: 0.3rem 0.8rem;
  font-size: 0.7rem;
}

.admin-empty,
.admin-loading {
  text-align: center;
  color: var(--white-muted);
  padding: var(--space-md);
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
  padding: var(--space-sm);
}

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

.modal {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  overflow-y: auto;
  padding: var(--space-md);
  position: relative;
}

.modal__close {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: none;
  border: none;
  color: var(--white-muted);
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
  transition: color var(--transition);
}

.modal__close:hover {
  color: var(--gold);
}

.modal__title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
  padding-right: var(--space-md);
}

.modal__dl {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.4rem 1rem;
  margin-bottom: var(--space-md);
}

.modal__dl dt {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--gold);
  padding-top: 0.15rem;
}

.modal__dl dd {
  color: var(--white-muted);
  font-size: 0.9rem;
  word-break: break-word;
}

/* Notes */
.modal__notes label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white-muted);
  margin-bottom: 0.3rem;
}

.modal__notes textarea {
  width: 100%;
  padding: 0.6rem 0.8rem;
  background: var(--black);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.9rem;
  resize: vertical;
  transition: border-color var(--transition);
}

.modal__notes textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.modal__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-sm);
}

.admin-flag-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--white-muted);
  font-size: 0.85rem;
  cursor: pointer;
}

.admin-flag-label input[type="checkbox"] {
  accent-color: var(--gold);
  width: 16px;
  height: 16px;
}

/* Mobile admin */
@media (max-width: 768px) {
  .admin-stats {
    flex-direction: column;
  }

  .admin-controls {
    flex-direction: column;
  }

  .admin-search {
    min-width: 100%;
  }

  .modal__dl {
    grid-template-columns: 1fr;
  }

  .modal__dl dt {
    margin-top: 0.5rem;
  }

  .admin-user-email {
    display: none;
  }

  .admin-table {
    font-size: 0.8rem;
  }
}

/* ==========================================================
   INTAKE FORM
   ========================================================== */

.intake {
  padding-top: 100px;
  min-height: 100vh;
}

.intake__card {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-lg) var(--space-md);
  max-width: 760px;
  margin: 0 auto;
}

.intake__header {
  text-align: center;
  margin-bottom: var(--space-md);
}

.intake__header h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: var(--space-xs);
}

.intake__sub {
  color: var(--white-muted);
  font-size: 0.95rem;
  max-width: 540px;
  margin: 0 auto;
}

/* Progress bar */
.intake__progress {
  height: 3px;
  background: var(--grey);
  border-radius: 2px;
  margin-bottom: var(--space-xs);
  overflow: hidden;
}

.intake__progress-bar {
  height: 100%;
  width: 0;
  background: var(--gold);
  transition: width 0.4s ease;
}

/* Step indicators */
.intake__steps {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-md);
}

.intake__step {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white-muted);
  opacity: 0.4;
  transition: opacity var(--transition), color var(--transition);
}

.intake__step.active {
  color: var(--gold);
  opacity: 1;
}

.intake__step.done {
  color: var(--white-muted);
  opacity: 0.7;
}

/* Panels */
.intake__panel {
  display: none;
}

.intake__panel.active {
  display: block;
}

.intake__panel h2 {
  font-size: 1.4rem;
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-xs);
  border-bottom: 1px solid var(--grey);
}

/* Fields */
.intake__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
}

.intake__field {
  margin-bottom: var(--space-sm);
}

.intake__field label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white-muted);
  margin-bottom: 0.3rem;
}

.intake__field input,
.intake__field select,
.intake__field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--black);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color var(--transition);
}

.intake__field input:focus,
.intake__field select:focus,
.intake__field textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.intake__field select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23bbb5a7' fill='none' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

.intake__field select option {
  background: var(--black-card);
  color: var(--white);
}

.intake__field textarea {
  resize: vertical;
  min-height: 80px;
}

/* Validation error state */
.intake__input--error {
  border-color: #e74c3c !important;
}

.intake__field--error {
  outline: 1px solid #e74c3c;
  border-radius: var(--radius);
  padding: 0.3rem;
}

/* Radio group */
.intake__radio-group {
  display: flex;
  gap: var(--space-md);
  padding: 0.5rem 0;
}

.intake__radio {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--white-muted);
  font-size: 0.95rem;
  cursor: pointer;
}

.intake__radio input[type="radio"] {
  accent-color: var(--gold);
  width: 16px;
  height: 16px;
}

/* Health checkbox grid */
.intake__health-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem var(--space-md);
  margin-top: var(--space-sm);
}

.intake__panel-intro {
  color: var(--white-muted);
  font-size: 0.95rem;
  margin-bottom: 0;
}

/* Consent box */
.intake__consent-box {
  background: var(--black);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-md);
  margin: var(--space-md) 0;
}

.intake__consent-box h3 {
  font-size: 1.1rem;
  margin-bottom: var(--space-sm);
  color: var(--gold);
}

.intake__consent-text {
  color: var(--white-muted);
  font-size: 0.88rem;
  line-height: 1.8;
  margin-bottom: var(--space-sm);
  white-space: pre-line;
  max-height: 340px;
  overflow-y: auto;
  padding-right: var(--space-xs);
}

.intake__consent-text ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-top: 0.5rem;
}

.intake__consent-text li {
  margin-bottom: 0.3rem;
}

/* Checkbox */
.intake__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: var(--white);
  font-size: 0.9rem;
  cursor: pointer;
  padding-top: var(--space-xs);
}

.intake__checkbox input[type="checkbox"] {
  accent-color: var(--gold);
  width: 18px;
  height: 18px;
  margin-top: 2px;
  flex-shrink: 0;
}

.intake__checkbox--consent {
  margin: var(--space-md) 0;
  font-weight: 600;
}

/* Signature section heading */
.intake__sig-section {
  margin-top: var(--space-sm);
}

.intake__sig-section h3 {
  font-size: 1.1rem;
  margin-bottom: var(--space-xs);
  color: var(--gold);
}

/* Navigation buttons */
.intake__nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-md);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--grey);
}

/* Signature pad */
.intake__sig-intro {
  color: var(--white-muted);
  font-size: 0.9rem;
  margin-bottom: var(--space-sm);
}

.intake__sig-wrap {
  position: relative;
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--black);
  margin-bottom: var(--space-xs);
}

.intake__sig-canvas {
  display: block;
  width: 100%;
  cursor: crosshair;
  touch-action: none;
}

.intake__sig-clear {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
}

.intake__sig-error {
  color: #e74c3c;
  font-size: 0.85rem;
  min-height: 1.2em;
}

/* Confirmation */
.intake__confirm {
  text-align: center;
  padding: var(--space-lg) 0;
}

.intake__confirm-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 3px solid var(--gold);
  color: var(--gold);
  font-size: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-md);
}

.intake__confirm h2 {
  margin-bottom: var(--space-sm);
}

.intake__confirm p {
  color: var(--white-muted);
  font-size: 1rem;
  max-width: 480px;
  margin: 0 auto var(--space-md);
}

.intake__confirm-actions {
  display: flex;
  gap: var(--space-sm);
  justify-content: center;
  flex-wrap: wrap;
}

/* Mobile intake */
@media (max-width: 768px) {
  .intake__card {
    padding: var(--space-md) var(--space-sm);
  }

  .intake__row {
    grid-template-columns: 1fr;
  }

  .intake__steps {
    gap: var(--space-xs);
  }

  .intake__step {
    font-size: 0.65rem;
  }

  .intake__nav {
    flex-direction: column-reverse;
    gap: var(--space-sm);
  }

  .intake__nav .btn {
    width: 100%;
    text-align: center;
  }

  .intake__health-grid {
    grid-template-columns: 1fr;
  }

  .intake__confirm-actions {
    flex-direction: column;
    align-items: center;
  }
}

/* ==========================================================
   QR CODE PAGE
   ========================================================== */

.qr {
  padding-top: 100px;
  min-height: 100vh;
}

.qr__card {
  background: var(--black-card);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: var(--space-lg) var(--space-md);
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.qr__header {
  margin-bottom: var(--space-md);
}

.qr__header h1 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin-bottom: var(--space-xs);
}

.qr__sub {
  color: var(--white-muted);
  font-size: 0.92rem;
  max-width: 460px;
  margin: 0 auto;
}

/* Theme toggle */
.qr__toggle-wrap {
  display: flex;
  justify-content: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
}

.qr__toggle.active {
  background: var(--gold);
  color: var(--black);
  border-color: var(--gold);
}

/* QR display area */
.qr__display {
  margin-bottom: var(--space-md);
}

.qr__canvas-wrap {
  display: inline-block;
  padding: var(--space-md);
  border-radius: var(--radius);
  transition: background var(--transition);
}

.qr__canvas-wrap--dark {
  background: var(--black);
  border: 1px solid var(--grey-light);
}

.qr__canvas-wrap--light {
  background: #ffffff;
  border: 1px solid #ddd;
}

.qr__url {
  margin-top: var(--space-sm);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Actions */
.qr__actions {
  margin-bottom: var(--space-md);
}

/* Note */
.qr__note {
  background: var(--black);
  border: 1px solid var(--grey);
  border-radius: var(--radius);
  padding: var(--space-sm);
  text-align: left;
}

.qr__note p {
  color: var(--white-muted);
  font-size: 0.8rem;
  margin-bottom: 0.3rem;
}

.qr__note code {
  display: block;
  color: var(--gold);
  font-size: 0.85rem;
  word-break: break-all;
  margin-bottom: 0.5rem;
}

.qr__note-hint {
  font-size: 0.75rem !important;
  color: var(--white-muted);
  opacity: 0.6;
}

@media (max-width: 768px) {
  .qr__card {
    padding: var(--space-md) var(--space-sm);
  }
}
