/* ===========================
   RESET & BASE STYLES
   =========================== */

:root {
    /* Logo-inspired theme */
    --bg-primary: #f5f2e8;
    --bg-secondary: #ece6d8;
    --bg-card: #fffaf0;
    --border-color: rgba(154, 103, 35, 0.28);
    --text-primary: #232018;
    --text-secondary: #5f5a4f;
    --text-heading: #17140f;
    --accent-primary: #6B7F54;
    --accent-hover: #819965;
    --accent-glow: rgba(154, 103, 35, 0.28);
    --accent-shadow: rgba(107, 127, 84, 0.28);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    opacity: 1;
    transition: background-color 0.3s ease, color 0.3s ease, opacity 0.5s ease;
}

body.is-loading {
    opacity: 0;
}

@media (prefers-reduced-motion: reduce) {

    body,
    body.is-loading {
        opacity: 1;
        transition: none;
    }
}

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

a {
    color: inherit;
}

ul {
    list-style: none;
}

/* ===========================
   GLOBAL SCROLLBARS
   =========================== */

/* Firefox: hidden by default, themed when hovered/focused */
* {
    scrollbar-width: thin;
    scrollbar-color: color-mix(in sRGB, var(--accent-primary) 10%, transparent) transparent;
    transition: scrollbar-color 0.3s ease;
}

*:hover,
*:focus-within {
    scrollbar-color: color-mix(in sRGB, var(--accent-primary) 50%, transparent) transparent;
}

/* WebKit: transparent track and hidden scrollbar until hover/focus */
*::-webkit-scrollbar {
    width: 10px;
    height: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

*:hover::-webkit-scrollbar,
*:focus-within::-webkit-scrollbar {
    opacity: 1;
}

*::-webkit-scrollbar-track {
    background: transparent;
}

*::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 999px;
}

*:hover::-webkit-scrollbar-thumb,
*:focus-within::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border: 2px solid transparent;
    background-clip: padding-box;
}

*:hover::-webkit-scrollbar-thumb:hover,
*:focus-within::-webkit-scrollbar-thumb:hover {
    background: var(--accent-hover);
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* ===========================
   TYPOGRAPHY
   =========================== */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Bebas Neue', 'Impact', sans-serif;
    font-weight: 400;
    letter-spacing: 0.05em;
    line-height: 1.2;
}

h1 {
    font-size: clamp(4rem, 12vw, 10rem);
}

h2 {
    font-size: clamp(2.5rem, 6vw, 4rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

/* ===========================
   LAYOUT UTILITIES
   =========================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 6rem 0;
    position: relative;
}

.section-alt {
    background-color: var(--bg-secondary);
    transition: background-color 0.3s ease;
}

.section-title {
    color: var(--text-heading);
    margin-bottom: 3rem;
    text-align: center;
    position: relative;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

*+.section-title {
    margin-top: 4rem;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--accent-primary);
    margin: 1rem auto 0;
    transition: background 0.3s ease;
}

/* ===========================
   BUTTONS
   =========================== */

.btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border: 2px solid var(--accent-primary);
    background: transparent;
    color: var(--text-heading);
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
}

.btn:hover {
    background: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--accent-shadow);
}

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

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.btn-large {
    padding: 1.25rem 3rem;
    font-size: 1.5rem;
}

/* ===========================
   NAVIGATION
   =========================== */

#nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding-top: 0.3rem;
    background: transparent;
    backdrop-filter: blur(0);
    z-index: 1000;
    border-bottom: 1px solid transparent;
    transition: background 0.35s ease, backdrop-filter 0.35s ease, border-color 0.35s ease;
}

#nav.scrolled {
    background: rgba(245, 242, 232, 0.88);
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    height: 6rem;
    padding-inline: 4rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.35s ease;
}

#nav.scrolled .nav-container {
    height: 3rem;
    padding-inline: 1rem;
}

.nav-logo {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 2rem;
    letter-spacing: 0.15em;
    color: var(--text-heading);
    transition: color 0.3s ease;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    height: 100%;
    padding-right: 2rem;
}

.nav-menu a {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    color: var(--text-primary);
    transition: color 0.3s ease;
    position: relative;
    text-decoration: none;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-primary);
    transition: width 0.3s ease, background 0.3s ease;
}

.nav-menu a:hover {
    color: var(--text-heading);
}

.nav-menu a.active {
    color: var(--accent-primary);
}

.nav-menu a.active::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background: var(--text-heading);
    transition: all 0.3s ease;
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        flex-direction: column;
        background: rgba(245, 242, 232, 0.98);
        width: 100%;
        padding: 2rem;
        gap: 1.5rem;
        transition: left 0.3s ease;
        border-top: 1px solid var(--border-color);
    }

    .nav-menu.active {
        left: 0;
    }

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

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

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

/* ===========================
    BACK TO TOP BUTTON
    =========================== */

.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: 2px solid var(--border-color);
    color: var(--text-heading);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px var(--accent-shadow);
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 30px var(--accent-glow);
}

.back-to-top .back-to-top-icon {
    width: 28px;
    height: 28px;
}

@media (max-width: 768px) {
    .back-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 50px;
        height: 50px;
    }

    .back-to-top .back-to-top-icon {
        width: 24px;
        height: 24px;
    }
}

/* ===========================
   HERO SECTION
   =========================== */

#hero {
    min-height: 120vh;
    display: flex;
    align-items: start;
    justify-content: center;
    text-align: center;
    position: relative;
}

@keyframes pulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.8;
    }
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.hero-title {
    color: var(--text-heading);
    text-transform: uppercase;
    margin-bottom: 1rem;
    text-shadow: 0 0 40px var(--accent-glow);
    letter-spacing: 0.2em;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.hero-subtitle {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: var(--accent-primary);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

/* ===========================
   HERO LOGO
   =========================== */
.hero-logo {
    display: inline-block;
    width: 100vw;
    max-width: none;
    transform: scale(1.1);
}

.hero-title,
.hero-subtitle {
    display: none;
}


/* ===========================
   MEMBERS SECTION
   =========================== */

#members {
    padding-bottom: 0;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    --time: 500ms;
}

#members .container {
    max-width: 100%;
    width: 100%;
    padding: 0;
}

#members .section-title {
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.55);
}

#members .section-title::after {
    margin-top: 0.5rem;
}

.band-grid {
    display: flex;
    align-items: center;
    width: 100%;
    height: 32rem;
    overflow: hidden;
    gap: 2rem;
    padding: 2rem;
}

.band-grid.has-open .band-member[data-open="false"] {
    filter: blur(3px);
}

.band-member {
    flex: 1;
    display: flex;
    background: var(--bg-card);
    border-radius: 1rem;
    cursor: pointer;
    overflow: hidden;
    transition: all var(--time) ease-in-out;
    will-change: flex;
}

.band-member[data-open="true"] {
    flex: 6;

    &.ben {
        .member-photo img {
            object-position: 15% 50%;
        }
    }

    &.ethan {
        .member-photo img {
            object-position: 25% 50%;
        }
    }

    .member-details {
        flex: 1;
        opacity: 1;
        transition: opacity 1s cubic-bezier(1, 0, 0, 1);

        .member-bio {
            font-size: 0.75rem;
            transition: font-size 750ms ease-in-out;
        }
    }
}

.member-photo {
    flex: 1;
    display: flex;
    position: relative;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    overflow: hidden;
}

.member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.member-photo-meta {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 2.2rem 1rem 0.85rem;
    background: linear-gradient(to top, rgba(23, 20, 15, 0.88) 0%, rgba(23, 20, 15, 0.56) 45%, rgba(23, 20, 15, 0) 100%);
    color: #fffaf0;
    pointer-events: none;
}

.member-photo-name {
    font-family: 'Bebas Neue', 'Impact', sans-serif;
    font-size: clamp(1.25rem, 1.9vw, 1.8rem);
    line-height: 1;
    letter-spacing: 0.06em;
}

.member-photo-role {
    font-size: clamp(0.75rem, 1vw, 0.95rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 250, 240, 0.9);
}

.member-details {
    flex: 0;
    background: var(--bg-card);
    overflow: hidden;
    opacity: 0;
    transition: all var(--time) ease-in-out;
    will-change: width, opacity;
}

.member-details-wrap {
    position: relative;
    height: 100%;
    width: 100%;
    padding: 1rem 1.25rem;
    overflow-y: auto;
    scrollbar-gutter: stable;
    transition: all var(--time) ease-in-out;
}

.member-name {
    color: var(--text-heading);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.member-role {
    font-size: 1.1rem;
    color: var(--accent-primary);
    letter-spacing: 0.15em;
    margin-bottom: 1rem;
}

.member-bio {
    color: var(--text-secondary);
    font-size: 0rem;
    line-height: 1.6;
    text-wrap: pretty;
    transition: font-size 0 ease-in-out;
}

/* ===========================
   SHOWS SECTION
   =========================== */

.shows-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 900px;
    margin: 0 auto;
}

.shows-list.shows-past {
    gap: 1rem;
}

.shows-list.shows-past .show-item {
    padding-block: 1rem;
}

.shows-list.shows-past .show-venue {
    font-size: 1.5rem;
}

.show-item {
    display: grid;
    grid-template-columns: 100px 1fr auto;
    gap: 2rem;
    align-items: center;
    padding: 2rem;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
}

.show-item:hover {
    border-color: var(--accent-primary);
    transform: translateX(10px);
    box-shadow: -5px 5px 0 var(--accent-shadow);
}

.show-date {
    text-align: center;
}

.date-month {
    display: block;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.5rem;
    color: var(--accent-primary);
    letter-spacing: 0.1em;
    transition: color 0.3s ease;
}

.date-day {
    display: block;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 3rem;
    color: var(--text-heading);
    line-height: 1;
    transition: color 0.3s ease;
}

.show-details h3 {
    color: var(--text-heading);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.show-location,
.show-time {
    color: var(--text-secondary);
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

@media (max-width: 768px) {
    .show-item {
        grid-template-columns: 80px 1fr;
        gap: 1.5rem;
    }

    .show-action {
        grid-column: 2;
        justify-self: start;
        margin-top: 1rem;
    }
}

/* ===========================
   MUSIC SECTION
   =========================== */

.music-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.music-embed {
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    overflow: hidden;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.music-embed:hover {
    border-color: var(--accent-primary);
}

.music-embed iframe {
    display: block;
    width: 100%;
    border: none;
}

/* Placeholder styling (remove when adding real embeds) */
.embed-placeholder {
    padding: 3rem 2rem;
    text-align: center;
    background: var(--bg-primary);
    min-height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.embed-placeholder p {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.5rem;
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.embed-placeholder small {
    color: var(--text-secondary);
    font-size: 0.85rem;
    transition: color 0.3s ease;
}

/* ===========================
   CONTACT SECTION
   =========================== */

.contact-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 4rem;
}

.contact-text {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin-bottom: 2rem;
    transition: color 0.3s ease;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.social-link {
    color: var(--text-primary);
    transition: all 0.3s ease;
    display: inline-flex;
}

.social-link:hover {
    color: var(--accent-primary);
    transform: translateY(-5px);
}

.social-link svg {
    width: 32px;
    height: 32px;
}

/* ===========================
   FOOTER
   =========================== */

.footer {
    background: var(--bg-secondary);
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    transition: background 0.3s ease, border-color 0.3s ease;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

/* ===========================
   RESPONSIVE DESIGN
   =========================== */

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

    .container {
        padding: 0 1.5rem;
    }

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

@media (max-width: 1024px) {
    .band-grid.has-open .band-member {
        flex: 0.75 1 0;
    }

    .band-grid.has-open .band-member[data-open="true"] {
        flex: 2.15 1 0;
    }

    .band-member[data-open="true"] .member-photo {
        width: min(100%, 300px);
    }
}

@media (max-width: 768px) {
    #members {
        margin-left: 0;
        width: 100%;
    }

    #members .section-title {
        position: static;
        pointer-events: auto;
        padding: 1.25rem 1rem 0;
        text-shadow: none;
    }

    .band-grid {
        height: auto;
        flex-direction: column;
    }

    .band-member,
    .band-grid.has-open .band-member,
    .band-grid.has-open .band-member[data-open="true"] {
        flex: 1 1 auto;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }


    .band-member .member-photo,
    .band-member[data-open="true"] .member-photo {
        width: 100%;
        aspect-ratio: 16 / 10;
        height: auto;
    }
}

@media (max-width: 480px) {
    .hero-subtitle {
        letter-spacing: 0.2em;
    }

    .btn {
        padding: 0.6rem 1.5rem;
        font-size: 1rem;
    }

    .btn-large {
        padding: 1rem 2rem;
        font-size: 1.25rem;
    }
}