/* barbershopky.com — The Barber Shop: black & gold, Godfather-style */

:root {
    --night: #101010;
    --panel: #191919;
    --panel-2: #222018;
    --ice: #f4efe6;
    --dim: #a89f8d;
    --glow: #c9a464;
    --glow-bright: #e0bc7d;
    --line: rgba(244, 239, 230, 0.13);
    --rail: 6.2rem;
    --font-display: "Playfair Display", "Georgia", serif;
    --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
    background: var(--night);
    color: var(--ice);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img, svg { max-width: 100%; }
a { color: var(--ice); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--glow); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 700; line-height: 1.1; }

.wrap { max-width: 70rem; margin: 0 auto; padding: 0 1.4rem; }

.kicker {
    font-weight: 700;
    font-size: 0.82rem;
    letter-spacing: 0.34em;
    text-transform: uppercase;
    color: var(--glow);
    display: block;
    margin-bottom: 0.6rem;
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.85rem 1.8rem;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.05em;
    text-decoration: none;
    border: 2px solid var(--glow);
    border-radius: 3px;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease, color 0.18s ease;
    cursor: pointer;
}
.btn svg { width: 1.1em; height: 1.1em; flex: none; fill: currentColor; }
.btn:hover { transform: translateY(-2px); }
.btn-solid { background: var(--glow); color: #171205; }
.btn-solid:hover { background: var(--glow-bright); border-color: var(--glow-bright); }
.btn-ghost { background: rgba(201, 164, 100, 0.08); color: var(--ice); }
.btn-ghost:hover { border-color: var(--glow-bright); color: #fff; }

/* ---------- Scroll progress ---------- */

/* Barber-pole progress: gold/black candy stripe that spins as you scroll */
.scroll-progress {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 4px;
    z-index: 70;
    background: repeating-linear-gradient(115deg, var(--glow) 0 10px, #171205 10px 20px);
    box-shadow: 0 0 12px rgba(201, 164, 100, 0.7);
    transform: scaleX(0);
    transform-origin: left;
    pointer-events: none;
}

/* ---------- Left rail (desktop) / top bar (mobile) ---------- */

.rail {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    width: var(--rail);
    z-index: 50;
    background: #0c0c0c;
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem 0.4rem;
    gap: 0.4rem;
}
.rail .rail-logo { width: 3.4rem; margin-bottom: 0.8rem; }
.rail a.rail-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    width: 100%;
    padding: 0.65rem 0.2rem;
    text-decoration: none;
    color: var(--dim);
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    border-radius: 6px;
    transition: color 0.15s ease, background 0.15s ease;
}
.rail a.rail-link:hover { color: var(--glow-bright); background: rgba(201, 164, 100, 0.08); }
.rail a.rail-link img { width: 1.9rem; height: 1.9rem; object-fit: contain; }
.rail .rail-book { margin-top: auto; width: 100%; }
.rail .rail-book a {
    display: block;
    text-align: center;
    background: var(--glow);
    color: #171205;
    font-weight: 800;
    font-size: 0.66rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 6px;
    padding: 0.7rem 0.2rem;
}
.rail .rail-book a:hover { background: var(--glow-bright); }

.topbar {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 50;
    align-items: center;
    gap: 1rem;
    padding: 0.6rem 1.2rem;
    background: rgba(12, 12, 12, 0.95);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--line);
}
.topbar img { height: 2.4rem; }
.topbar .btn { margin-left: auto; padding: 0.5rem 1.1rem; font-size: 0.95rem; }

main, .site-footer { margin-left: var(--rail); }

@media (max-width: 60rem) {
    .rail { display: none; }
    .topbar { display: flex; }
    main, .site-footer { margin-left: 0; }
}

/* ---------- Hero ---------- */

.hero {
    position: relative;
    min-height: min(100svh, 56rem);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: var(--night);
}
.hero-bg {
    position: absolute;
    inset: -12% 0;
    z-index: 0;
    background:
        linear-gradient(to bottom, rgba(16, 16, 16, 0.82), rgba(16, 16, 16, 0.55) 55%, var(--night)),
        url("/images/hero.webp") center 62% / cover no-repeat;
    will-change: transform;
}
.hero-inner { position: relative; z-index: 2; padding: 6rem 1.4rem 5rem; max-width: 46rem; }
.hero-logo { width: min(30rem, 78vw); margin: 0 auto; filter: drop-shadow(0 10px 34px rgba(0, 0, 0, 0.75)); }
.hero .tagline {
    font-family: var(--font-display);
    font-size: clamp(1.05rem, 2.4vw, 1.35rem);
    color: var(--ice);
    margin-top: 1.4rem;
}
.hero .sub { color: var(--dim); font-size: 0.98rem; margin-top: 0.4rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; justify-content: center; margin-top: 2rem; }

/* ---------- Marquee ---------- */

.marquee {
    position: relative;
    z-index: 2;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: var(--panel);
    overflow: hidden;
    padding: 0.7rem 0;
}
.marquee-track { display: flex; gap: 3rem; width: max-content; animation: marquee 34s linear infinite; }
.marquee span {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.98rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--dim);
    white-space: nowrap;
}
.marquee span::after { content: "✂"; color: var(--glow); margin-left: 3rem; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Story ---------- */

.story { padding: 6rem 0 3rem; }
.section-title { font-size: clamp(1.9rem, 5vw, 2.9rem); margin-bottom: 1.6rem; }
.section-title::after {
    content: "";
    display: block;
    width: 4.5rem;
    height: 3px;
    margin-top: 0.9rem;
    background: linear-gradient(90deg, var(--glow), transparent);
    transform-origin: left;
}
.story-grid { display: grid; grid-template-columns: 1.25fr 0.9fr; gap: 3rem; align-items: center; }
.story p { color: var(--ice); margin-bottom: 1rem; }
.story p strong { color: var(--glow-bright); }
.story .aside { color: var(--dim); font-size: 0.98rem; }
.story-photo { border-radius: 6px; border: 1px solid var(--line); width: 100%; height: auto; filter: saturate(0.95); }
@media (max-width: 52rem) { .story-grid { grid-template-columns: 1fr; gap: 2rem; } }

/* ---------- Services ---------- */

.services { padding: 4rem 0 2rem; }
.service-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.1rem; }
.service-card {
    background: linear-gradient(170deg, var(--panel), var(--panel-2));
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1.6rem 1.3rem;
    text-align: center;
    text-decoration: none;
    display: block;
    transition: border-color 0.2s ease, transform 0.2s ease;
}
.service-card:hover { border-color: rgba(201, 164, 100, 0.5); transform: translateY(-3px); }
.service-card img { width: 3.4rem; height: 3.4rem; object-fit: contain; margin: 0 auto 0.8rem; display: block; }
.service-card h3 { font-size: 1.15rem; color: var(--ice); }
.service-card p { color: var(--dim); font-size: 0.85rem; margin-top: 0.3rem; }
@media (max-width: 60rem) { .service-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Booking banner ---------- */

.booking-banner {
    margin: 4rem 0;
    background:
        radial-gradient(ellipse 70% 120% at 85% 50%, rgba(201, 164, 100, 0.16), transparent 60%),
        var(--panel);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 3.2rem 0;
}
.booking-banner .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 1.6rem 3rem; }
.booking-banner h2 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); }
.booking-banner p { color: var(--dim); margin-top: 0.4rem; max-width: 34em; }
.booking-banner p strong { color: var(--glow-bright); }
.booking-banner .btn { margin-left: auto; }
@media (max-width: 52rem) { .booking-banner .btn { margin-left: 0; } }

/* ---------- Gallery ---------- */

.work { padding: 2rem 0; }
.work-section { padding: 2.4rem 0 3.2rem; }
.work-head { display: flex; align-items: baseline; gap: 1.1rem; margin-bottom: 3.2rem; position: relative; z-index: 2; }
.work-head h2 { font-size: clamp(1.6rem, 4.2vw, 2.3rem); }
.work-head .count {
    font-weight: 700;
    color: var(--dim);
    font-size: 0.82rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.work-grid { columns: 4 14rem; column-gap: 0.9rem; }
.work-grid.cols { columns: unset; display: flex; gap: 0.9rem; align-items: flex-start; }
.work-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.9rem; will-change: transform; }
.work-grid.cols a { margin-bottom: 0; }
.work-grid a {
    position: relative;
    display: block;
    margin-bottom: 0.9rem;
    break-inside: avoid;
    overflow: hidden;
    border-radius: 6px;
    background: var(--panel);
    border: 1px solid var(--line);
}
.work-grid img { width: 100%; height: auto; transition: transform 0.4s ease, opacity 0.4s ease; display: block; }
.work-grid a:hover img { transform: scale(1.04); }
.work-empty {
    border: 2px dashed var(--line);
    border-radius: 8px;
    text-align: center;
    color: var(--dim);
    padding: 3rem 1.4rem;
}
@media (max-width: 46rem) {
    .work-grid { columns: 2; column-gap: 0.6rem; }
    .work-grid a { margin-bottom: 0.6rem; }
}

/* ---------- Products ---------- */

.products { padding: 4rem 0; }
.product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; max-width: 54rem; }
.product-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1.4rem;
    text-align: center;
}
.product-card img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }
.product-card h3 { font-size: 1.05rem; margin-top: 0.9rem; color: var(--ice); }
.products .aside { color: var(--dim); font-size: 0.95rem; margin-top: 1.4rem; }
@media (max-width: 46rem) { .product-grid { grid-template-columns: 1fr; } }

/* ---------- Details / contact ---------- */

.contact {
    padding: 5.5rem 0;
    background:
        radial-gradient(ellipse 80% 90% at 50% 118%, rgba(201, 164, 100, 0.14), transparent 60%),
        var(--panel);
    border-top: 1px solid var(--line);
}
.contact-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 3rem; align-items: start; }
.contact h3 { font-size: 1.05rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--glow); margin: 1.5rem 0 0.4rem; }
.contact h3:first-of-type { margin-top: 0; }
.contact address { font-style: normal; }
.contact a { color: var(--ice); text-decoration-color: rgba(201, 164, 100, 0.5); }
.contact a:hover { color: #fff; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 1.8rem; }
.contact-photo img { border-radius: 6px; border: 1px solid var(--line); width: 100%; height: auto; }
.contact-photo figcaption { color: var(--dim); font-size: 0.9rem; margin-top: 0.6rem; }
@media (max-width: 52rem) { .contact-grid { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); padding: 2.2rem 0 5.5rem; color: var(--dim); font-size: 0.92rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 2rem; }
.site-footer a { color: var(--dim); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer img { height: 2rem; }

/* ---------- Mobile book bar ---------- */

.call-bar { position: fixed; bottom: 0; left: 0; right: 0; z-index: 60; display: none; }
.call-bar a {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.95rem;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.05rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-decoration: none;
    color: #171205;
    background: var(--glow);
}
@media (max-width: 46rem) { .call-bar { display: flex; } }

/* ---------- Lightbox ---------- */

.lightbox {
    position: fixed; inset: 0; z-index: 100;
    display: none; align-items: center; justify-content: center;
    background: rgba(8, 8, 8, 0.95);
    padding: 2.5rem;
}
.lightbox.open { display: flex; }
.lightbox img {
    max-width: min(92vw, 62rem);
    max-height: 86vh;
    border-radius: 6px;
    border: 1px solid var(--line);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.7);
}
.lightbox button {
    position: absolute;
    background: rgba(244, 239, 230, 0.08);
    color: var(--ice);
    border: 1px solid var(--line);
    border-radius: 50%;
    width: 2.9rem; height: 2.9rem;
    font-size: 1.4rem; line-height: 1;
    cursor: pointer;
    transition: background 0.15s ease;
}
.lightbox button:hover { background: var(--glow); color: #171205; }
.lb-close { top: 1.1rem; right: 1.1rem; }
.lb-prev { left: 1.1rem; top: 50%; transform: translateY(-50%); }
.lb-next { right: 1.1rem; top: 50%; transform: translateY(-50%); }
.lb-caption {
    position: absolute;
    bottom: 1.1rem; left: 50%;
    transform: translateX(-50%);
    color: var(--dim);
    font-weight: 700;
    letter-spacing: 0.1em;
    font-size: 0.9rem;
    text-transform: uppercase;
}

/* ---------- Motion (JS + motion-ok only) ---------- */

@media (prefers-reduced-motion: no-preference) {
    html.js .reveal {
        opacity: 0;
        transform: translateY(28px);
        transition: opacity 0.8s ease, transform 0.8s ease;
        transition-delay: var(--d, 0s);
    }
    html.js .reveal.in { opacity: 1; transform: none; }

    html.js .section-title.reveal::after {
        transform: scaleX(0);
        transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.25s;
    }
    html.js .section-title.reveal.in::after { transform: scaleX(1); }

    /* Gallery tiles: a straight-razor sweep of black clears off each photo */
    html.js .work-item::after {
        content: "";
        position: absolute;
        inset: -2%;
        background: linear-gradient(105deg, rgba(16, 16, 16, 0.4), rgba(10, 10, 10, 0.97) 45%, #060606);
        transform: translateX(0);
        transition: transform 1s cubic-bezier(0.55, 0, 0.2, 1);
        transition-delay: var(--d, 0s);
    }
    html.js .work-item.in::after { transform: translateX(112%); }
    html.js .work-item.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.7s ease; transition-delay: var(--d, 0s); }
    html.js .work-item.reveal.in { opacity: 1; transform: none; }

    .scroll-progress { animation: pole-spin 1.1s linear infinite; }
    @keyframes pole-spin { to { background-position: 27px 0; } }

    /* The logo hangs from puppet strings — let it sway */
    .hero-logo { transform-origin: 50% -30%; animation: logo-sway 7s ease-in-out 1.2s infinite; }
    @keyframes logo-sway {
        0%, 100% { rotate: 0.7deg; }
        50%      { rotate: -0.7deg; }
    }

    /* Scissors cut the section underline open */
    .section-title { position: relative; }
    html.js .section-title.reveal::before {
        content: "✂";
        position: absolute;
        left: -0.2em;
        bottom: -0.32em;
        font-size: 0.5em;
        color: var(--glow-bright);
        opacity: 0;
        transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.25s, opacity 0.2s ease 0.25s;
    }
    html.js .section-title.reveal.in::before { opacity: 1; transform: translateX(4.9rem); }

    /* Occasional shine across the gold Book Now buttons */
    .btn-solid { position: relative; overflow: hidden; }
    .btn-solid::after {
        content: "";
        position: absolute;
        top: 0; bottom: 0;
        width: 45%;
        left: -70%;
        background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.55), transparent);
        transform: skewX(-20deg);
        animation: shine 4s ease-in-out 2s infinite;
    }
    @keyframes shine {
        0%, 72% { left: -70%; }
        100%    { left: 140%; }
    }

    .hero-bg { animation: hero-zoom 2.2s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
    .hero-inner > * { animation: rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
    .hero-inner > :nth-child(2) { animation-delay: 0.15s; }
    .hero-inner > :nth-child(3) { animation-delay: 0.3s; }
    .hero-inner > :nth-child(4) { animation-delay: 0.45s; }
    @keyframes hero-zoom { from { transform: scale(1.06); } to { transform: scale(1); } }
    @keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

    .lightbox.open img { animation: lb-pop 0.32s cubic-bezier(0.2, 0.9, 0.3, 1); }
    @keyframes lb-pop { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
}
