/* ===== Tokens ===== */
:root{
  --bg:#0f1113; --bg2:#15181c; --card:#121418;
  --text:#ECEFF3; --muted:#9EA4AC; --stroke:#262C32;
  --gold:#D8A24A; --gold10:rgba(216,162,74,.10); --gold20:rgba(216,162,74,.20);
  --shadow:0 8px 32px rgba(0,0,0,.35);
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{background:var(--bg);color:var(--text);font-family:Inter,system-ui,Segoe UI,Roboto,Arial,sans-serif;line-height:1.65;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
a{color:var(--text)}
.container{width:min(1120px,92%);margin:0 auto}
h1,h2,h3,h4,.headline,.subheadline{font-family:Oswald,Impact,Haettenschweiler,'Arial Narrow Bold',sans-serif;letter-spacing:.02em}

/* ===== Buttons ===== */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:10px;padding:14px 20px;border-radius:12px;
  font-weight:700;letter-spacing:.02em;text-decoration:none;transition:.2s ease;border:2px solid transparent;box-shadow:var(--shadow)}
.btn--primary{background:var(--gold);color:#171717}
.btn--outline{border-color:var(--gold);background:transparent;color:var(--text)}
.btn--ghost{background:transparent;border:1px dashed var(--gold20);color:var(--text)}
.btn--stretch{width:100%}
.btn--lg{padding:16px 26px;font-size:18px}
.btn--xs{padding:8px 12px;font-size:13px;box-shadow:none}
.btn:hover{transform:translateY(-1px)}

/* ===== Topbar ===== */
.topbar{position:sticky;top:0;z-index:50;background:rgba(15,17,19,.85);backdrop-filter:blur(8px);border-bottom:1px solid var(--stroke)}
.topbar__in{display:flex;align-items:center;justify-content:space-between;padding:10px 0}
.brand-mini{display:flex;align-items:center;gap:10px;text-decoration:none}
.logo-ring{width:40px;height:40px;display:grid;place-items:center;border-radius:50%;border:2px solid var(--gold);background:radial-gradient(circle at 30% 30%,var(--gold10),transparent 60%);font-family:Oswald;font-weight:700;color:var(--gold)}
.brand-mini__name{font-family:Oswald;font-weight:700;letter-spacing:.06em}
.nav{display:flex;align-items:center;gap:18px}
.nav a{text-decoration:none;color:var(--muted);font-weight:600}
.nav a:hover{color:#fff}
.nav__cta{margin-left:6px}
.burger{display:none;flex-direction:column;gap:4px;background:transparent;border:0}
.burger span{width:24px;height:2px;background:#fff;border-radius:2px}

/* ===== Hero ===== */
.hero{position:relative;min-height:86vh;display:flex;align-items:center;background:
  radial-gradient(900px 360px at 80% -10%, rgba(216,162,74,.10), transparent 60%),
  linear-gradient(180deg,var(--bg2),var(--bg)),
  var(--hero) center/cover no-repeat;
}
.hero::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.35),rgba(0,0,0,.6))}
.hero__in{position:relative;z-index:1;display:flex;flex-direction:column;gap:24px;padding:60px 0}
.logo-ring--xl{width:74px;height:74px;border-width:2px;font-size:34px}
.hero__brand{display:flex;align-items:center;gap:18px;flex-wrap:wrap}
.hero h1{margin:0;font-size:clamp(26px,5.2vw,48px);font-weight:700;letter-spacing:.04em}
.kicker{margin:.2rem 0 0;font-weight:700;text-transform:uppercase;letter-spacing:.06em}
.tagline{margin:.2rem 0 0;color:var(--muted)}
.hero__cta .hint{margin-top:10px;color:var(--muted);font-size:14px}
.arrow-down{width:18px;height:18px;border-bottom:3px solid var(--gold);border-right:3px solid var(--gold);transform:rotate(45deg);margin:10px auto 0}

/* ===== Sections ===== */
.section{padding:72px 0}
.headline{font-weight:700;font-size:clamp(28px,4vw,36px);text-transform:uppercase;display:inline-block;position:relative;margin:0 0 26px}
.headline::after{content:"";position:absolute;left:0;bottom:-8px;width:64px;height:3px;background:var(--gold);border-radius:2px}
.subheadline{margin:36px 0 10px;font-family:Oswald;font-weight:500;color:var(--muted);text-transform:uppercase}
.grid-2{display:grid;grid-template-columns:1.1fr .9fr;gap:28px}
@media (max-width:900px){.grid-2{grid-template-columns:1fr}}

/* ===== About Card ===== */
.about-card{border:1px solid var(--stroke);background:linear-gradient(180deg,#14171b,#0f1113);border-radius:14px;padding:22px}
.about-card__head{display:flex;align-items:center;gap:10px}
.about-card__head h3{margin:0}
.divider{flex:1;height:1px;background:var(--stroke)}
.badges{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.badge{border:1px solid var(--gold);color:var(--gold);padding:6px 10px;border-radius:999px;font-weight:700;font-size:12px}

/* ===== Cards ===== */
.cards{display:grid;gap:16px}
.cards--services{grid-template-columns:repeat(4,1fr)}
@media (max-width:960px){.cards--services{grid-template-columns:repeat(2,1fr)}}
@media (max-width:520px){.cards--services{grid-template-columns:1fr}}
.card{border:1px solid var(--stroke);border-radius:14px;background:var(--card);padding:20px}
.service h3{margin:0 0 6px}
.price{font-size:18px;color:var(--gold);font-weight:800}

/* ===== Table (Prices) ===== */
.table{border:1px solid var(--stroke);border-radius:14px;overflow:hidden;margin-top:12px}
.tr{display:grid;grid-template-columns:1fr auto;gap:12px;padding:14px 16px;border-bottom:1px solid var(--stroke)}
.tr:last-child{border-bottom:none}

/* ===== Branches ===== */
.cards--branches{grid-template-columns:repeat(2,1fr)}
@media (max-width:900px){.cards--branches{grid-template-columns:1fr}}
.branch header{display:flex;justify-content:space-between;align-items:center;gap:10px}
.branch h3{margin:0}
.chip{border:1px solid var(--stroke);padding:4px 8px;border-radius:999px;color:var(--muted);font-size:12px}
.meta a{text-decoration:none}

/* ===== Team ===== */
.cards--team{grid-template-columns:repeat(4,1fr)}
@media (max-width:1100px){.cards--team{grid-template-columns:repeat(3,1fr)}}
@media (max-width:740px){.cards--team{grid-template-columns:repeat(2,1fr)}}
@media (max-width:460px){.cards--team{grid-template-columns:1fr}}
.barber{display:flex;align-items:center;gap:14px}
.avatar{width:64px;height:64px;border-radius:10px;background:#1a1f24;border:1px solid var(--stroke);display:grid;place-items:center;font-weight:800;font-family:Oswald;color:var(--gold)}

/* ===== Works ===== */
.gallery{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
@media (max-width:740px){.gallery{grid-template-columns:repeat(2,1fr)}}
@media (max-width:460px){.gallery{grid-template-columns:1fr}}
.ph{aspect-ratio:1/1;border:1px solid var(--stroke);border-radius:12px;background:
  linear-gradient(180deg, rgba(216,162,74,.08), transparent 40%),
  linear-gradient(180deg,#171a1d,#0f1113)}

/* ===== Contacts ===== */
.links{list-style:none;padding:0;margin:0}
.links li{margin:6px 0}
.contacts__cta{align-self:center}

/* ===== Footer ===== */
.footer{border-top:1px solid var(--stroke);background:#0d0f11;padding:18px 0;color:var(--muted)}
.footer__in{display:flex;align-items:center;justify-content:space-between}
.to-top{text-decoration:none;color:var(--muted)}
.to-top:hover{color:#fff}

/* ===== Responsive Nav ===== */
@media (max-width:900px){
  .burger{display:flex}
  .nav{position:fixed;inset:60px 0 auto 0;background:rgba(15,17,19,.98);border-bottom:1px solid var(--stroke);transform:translateY(-120%);transition:.25s;flex-direction:column;padding:14px 20px;gap:14px}
  .nav.open{transform:translateY(0)}
}

/* Logo image */
.brand-logo{height:36px;width:auto;display:block;filter: brightness(1) contrast(1.05);}
.brand-logo--xl{height:88px;}
.brand-mini{gap:12px}
/* Optional: make white logo invert on dark bg if needed */
/* .brand-logo{filter: invert(1);} */

/* Barber thumbnails */
.barber .thumb{
  width: 72px;
  height: 72px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  object-fit: cover;
  background:#1a1f24;
}
@media (min-width: 720px){
  .barber .thumb{ width: 84px; height: 84px; }
}

/* Works gallery */
.works-gallery{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
  gap:20px;
  margin-top:30px;
}
.works-gallery img{
  width:100%;
  aspect-ratio:1/1;
  object-fit:cover;
  border-radius:14px;
  border:1px solid var(--stroke);
  background:#1a1f24;
  cursor:pointer;
  transition:transform .2s;
}
.works-gallery img:hover{ transform:scale(1.03); }

/* Works gallery thumbnails */
.gallery a.work{display:block; border:1px solid var(--stroke); border-radius:12px; overflow:hidden; position:relative}
.gallery a.work img{width:100%; aspect-ratio:1/1; object-fit:cover; display:block; transition:transform .25s ease}
.gallery a.work:hover img{transform:scale(1.03)}

/* Lightbox */
.lightbox{position:fixed; inset:0; display:none; align-items:center; justify-content:center; z-index:100}
.lightbox.open{display:flex}
.lightbox__backdrop{position:absolute; inset:0; background:rgba(0,0,0,.8)}
.lightbox__img{position:relative; max-width:min(92vw,1400px); max-height:86vh; border-radius:12px; border:1px solid var(--stroke); box-shadow:var(--shadow)}
.lightbox__close{position:fixed; top:14px; right:14px; background:transparent; border:0; color:#fff; font-size:32px; line-height:1; cursor:pointer}

/* Round logo */
header .logo img{
  border-radius:50%;
  border:2px solid var(--stroke);
}

/* ===== Polished Theme Enhancements ===== */
:root{ --radius:14px; }

.brand-logo{ height:40px; width:40px; border-radius:50%; border:2px solid var(--stroke); object-fit:cover; }
.brand-logo--xl{ height:96px; width:96px; border-radius:50%; border:2px solid var(--stroke); }

.section{ padding:88px 0; }
.card{ border-radius:var(--radius); transition: transform .2s ease, box-shadow .2s ease; }
.card:hover{ transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.35); }

.note-hours{ margin-top:-6px; margin-bottom:16px; color:var(--muted); }

/* Branch card rows */
.branch .meta, .branch .hours{ color:var(--muted); margin:6px 0; }
.branch .hours{ position:relative; padding-left:26px; }
.branch .hours::before{
  content:""; position:absolute; left:0; top:4px; width:18px; height:18px;
  border-radius:50%; border:1px solid var(--stroke);
  background: radial-gradient(circle at 30% 30%, var(--gold10), transparent 70%);
}

/* Section separators */
.section--about, .section--services, .section--prices, .section--branches, .section--team, .section--works, .section--contacts{
  border-top: 1px solid var(--stroke);
  border-bottom: 1px solid var(--stroke);
}

/* Masters grid 2 columns */
#team .grid.grid--2col{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(320px,1fr));
  gap:32px;
}
#team .card.barber img.thumb{ width:100%; border-radius:14px; }

/* Price list */
.price-list{ list-style:none; padding:0; margin:32px 0; border-top:1px solid var(--stroke); }
.price-list li{ display:flex; justify-content:space-between; align-items:center;
  padding:12px 0; border-bottom:1px solid var(--stroke); font-size:1rem; }
.price-list li:hover{ background:rgba(255,255,255,.02); }
.service-name{ color:var(--text); }
.service-price{ color:var(--gold); font-weight:600; }

/* Team: 2-column big cards */
.cards--team{grid-template-columns: repeat(2, 1fr) !important}
@media (max-width: 740px){ .cards--team{grid-template-columns: 1fr !important} }

.card.barber{flex-direction: column; align-items: flex-start; padding: 18px}
.barber .thumb{ width: 180px; height: 180px; border-radius: 16px }
@media (max-width: 900px){ .barber .thumb{ width: 150px; height: 150px } }
.barber h4{font-size: 20px; margin-top: 6px}
.barber p{font-size: 14px}

/* Team thumbnails: better crop and full-width inside card */
.card.barber{flex-direction: column; align-items: stretch; gap: 10px}
.barber .thumb{
  width: 100%;
  max-width: 420px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center top;
  border-radius: 16px;
  border: 1px solid var(--stroke);
}
.cards--team{grid-template-columns: repeat(2, minmax(0,1fr)) !important}
@media (max-width: 740px){ .cards--team{grid-template-columns: 1fr !important} }

/* Force square barber photos */
.barber .thumb{
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
  border-radius: 16px;
}

/* Adaptive thumbnail fit */
.barber .thumb{
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
  border-radius: 16px;
  background: #111;
}
@media (max-width: 740px){
  .barber .thumb{
    object-fit: contain;
    background: #111;
    padding: 4px;
  }
}

/* Adaptive framing for master photos */
.barber .thumb{ object-fit: cover; object-position: center top; }
@media (max-width: 640px){
  .barber .thumb{
    object-fit: contain;
    background: linear-gradient(180deg,#15181c,#0f1113);
    padding: 6px; /* tiny breathing room to avoid touching edges */
    border-radius: 16px; /* keep same */
  }
}
