/* Custom scrollbar styles */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #111621;
}

::-webkit-scrollbar-thumb {
    background: #374151;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #4b5563;
}

/* Material Symbols Outlined font settings */
.material-symbols-outlined {
    font-variation-settings:
        'FILL' 1,
        'wght' 400,
        'GRAD' 0,
        'opsz' 24;
}

/* Artist image grayscale effect */
.artist-image {
    filter: grayscale(100%);
    transition: filter 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.group:hover .artist-image {
    filter: grayscale(0%);
    transform: scale(1.05);
}

/* Navigation hover state - desktop only */
@media (min-width: 768px) {
    nav a {
        position: relative;
        display: inline-block;
    }

    /* Reserve space for bold text to prevent layout shift */
    nav a::before {
        content: attr(data-text);
        display: block;
        height: 0;
        visibility: hidden;
        overflow: hidden;
        user-select: none;
        pointer-events: none;
        font-weight: 700;
        white-space: nowrap;
    }

    nav a:hover {
        font-weight: 700;
    }
}

/* Typography System - Unified sizing for headers and text elements */
/* H1 - Logo/Brand name */
h1 {
    font-size: 1.125rem; /* text-lg */
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.25;
}

/* H2 - Main page headings */
h2 {
    font-size: 2.25rem; /* text-4xl base */
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-bottom: 2rem; /* mb-8 - uniform spacing when text wraps */
}

/* Responsive h2 - standardize to text-4xl md:text-5xl lg:text-6xl */
@media (min-width: 768px) {
    h2:not(.text-5xl):not(.text-6xl):not(.text-7xl):not(.signup-drawer-header h2) {
        font-size: 3rem; /* text-5xl md */
    }
}

@media (min-width: 1024px) {
    h2:not(.text-7xl):not(.signup-drawer-header h2) {
        font-size: 3.75rem; /* text-6xl lg */
    }
}

/* H3 - Section headings */
h3 {
    font-size: 1.5rem; /* text-2xl */
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.25;
}

/* H4 - Subheadings */
h4 {
    font-size: 1.125rem; /* text-lg */
    font-weight: 700;
    line-height: 1.5;
}

/* H5 - Small subheadings (if used) */
h5 {
    font-size: 1rem; /* text-base */
    font-weight: 700;
    line-height: 1.5;
}

/* H6 - Smallest headings (if used) */
h6 {
    font-size: 0.875rem; /* text-sm */
    font-weight: 700;
    line-height: 1.5;
}

/* Body text hierarchy */
p {
    font-size: 1rem; /* text-base - default */
    line-height: 1.75;
}

/* Large body text */
.text-lg,
p.text-lg {
    font-size: 1.125rem;
    line-height: 1.75;
}

/* Small body text */
.text-sm,
p.text-sm {
    font-size: 0.875rem;
    line-height: 1.625;
}

/* Extra small text */
.text-xs,
p.text-xs {
    font-size: 0.75rem;
    line-height: 1.5;
}

/* Override Tailwind classes to ensure consistency */
/* Standardize h2 sizes - all h2 should follow: text-4xl md:text-5xl lg:text-6xl */
/* Also enforce uniform spacing (line-height, letter-spacing, margin) for wrapped text */
h2.text-4xl,
h2.text-5xl,
h2.text-6xl,
h2.text-7xl,
h2.text-3xl {
    letter-spacing: -0.03em !important;
    line-height: 1.1 !important;
}

/* Ensure uniform margin-bottom for all h2 elements when text wraps */
h2.mb-6 {
    margin-bottom: 2rem !important; /* Override mb-6 to mb-8 for consistency */
}

h2.text-4xl {
    font-size: 2.25rem;
}

h2.text-5xl {
    font-size: 3rem;
}

h2.text-6xl {
    font-size: 3.75rem;
}

h2.text-7xl {
    font-size: 4.5rem;
}

h2.text-3xl {
    font-size: 1.875rem;
}

@media (min-width: 768px) {
    h2.text-4xl {
        font-size: 3rem; /* md:text-5xl */
    }
    h2.text-5xl {
        font-size: 3rem;
    }
    h2.text-6xl {
        font-size: 3.75rem;
    }
    h2.text-7xl {
        font-size: 4.5rem;
    }
}

@media (min-width: 1024px) {
    h2.text-4xl {
        font-size: 3.75rem; /* lg:text-6xl */
    }
    h2.text-5xl {
        font-size: 3.75rem; /* lg:text-6xl */
    }
    h2.text-6xl {
        font-size: 3.75rem;
    }
    h2.text-7xl {
        font-size: 4.5rem; /* Keep at 7xl for hero sections */
    }
}

/* Ensure h3 consistency - standardize to text-2xl */
h3.text-2xl {
    font-size: 1.5rem;
}

h3.text-3xl {
    font-size: 1.875rem; /* Allow for special cases, but prefer text-2xl */
}

h3.text-xl {
    font-size: 1.25rem; /* Allow for smaller h3, but prefer text-2xl */
}

h3.text-lg {
    font-size: 1.125rem; /* Allow for smaller h3, but prefer text-2xl */
}

/* Ensure h4 consistency - standardize to text-lg */
h4.text-lg {
    font-size: 1.125rem;
}

h4.text-xl {
    font-size: 1.25rem; /* Allow for larger h4, but prefer text-lg */
}

h4.text-base {
    font-size: 1rem; /* Allow for smaller h4, but prefer text-lg */
}

/* Ensure h4 without size class gets default */
h4:not([class*="text-"]) {
    font-size: 1.125rem; /* text-lg default */
}

/* Focus-visible styles for accessibility */
button:focus-visible,
a:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* Additional scrollbar styles for dark theme variations */
/* Override for pages with darker background-dark color */
.dark.bg-background-dark ::-webkit-scrollbar-track,
html.dark body.bg-background-dark ::-webkit-scrollbar-track {
    background: #0f1923;
}

.dark.bg-background-dark ::-webkit-scrollbar-thumb,
html.dark body.bg-background-dark ::-webkit-scrollbar-thumb {
    background: #1f2937;
}

.dark.bg-background-dark ::-webkit-scrollbar-thumb:hover,
html.dark body.bg-background-dark ::-webkit-scrollbar-thumb:hover {
    background: #374151;
}

/* Mobile Navigation Drawer */
.mobile-drawer-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 40;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 280px;
    max-width: 85vw;
    background-color: white;
    box-shadow: -4px 0 6px rgba(0, 0, 0, 0.1);
    z-index: 50;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.dark .mobile-drawer {
    background-color: #161b26;
    border-left: 1px solid #374151;
}

.mobile-drawer.active {
    transform: translateX(0);
}

.mobile-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e7ebf3;
}

.dark .mobile-drawer-header {
    border-bottom-color: #374151;
}

.mobile-drawer-close {
    background: none;
    border: none;
    color: #0e121b;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}

.dark .mobile-drawer-close {
    color: white;
}

.mobile-drawer-close:hover {
    opacity: 0.7;
}

.mobile-drawer-content {
    flex: 1;
    padding: 1rem 0;
}

.mobile-drawer-nav {
    display: flex;
    flex-direction: column;
}

.mobile-drawer-nav a {
    display: block;
    padding: 0.875rem 1.5rem;
    color: #374151;
    text-decoration: none;
    font-size: 0.875rem;
    transition: background-color 0.2s, color 0.2s;
}

.dark .mobile-drawer-nav a {
    color: #d1d5db;
}

.mobile-drawer-nav a:hover {
    background-color: #f3f4f6;
    color: #0e121b;
}

.dark .mobile-drawer-nav a:hover {
    background-color: #1f2937;
    color: white;
}

.mobile-drawer-nav a.active {
    background-color: #f0f4ff;
    color: #1754cf;
    font-weight: 700;
}

.dark .mobile-drawer-nav a.active {
    background-color: #1e3a5f;
    color: #1754cf;
}

.mobile-drawer-divider {
    height: 1px;
    background-color: #e7ebf3;
    margin: 0.5rem 0;
}

.dark .mobile-drawer-divider {
    background-color: #374151;
}

.mobile-drawer-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e7ebf3;
}

.dark .mobile-drawer-footer {
    border-top-color: #374151;
}

/* Prevent body scroll when drawer is open */
body.drawer-open {
    overflow: hidden;
}

/* Signup Drawer */
.signup-drawer-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 60;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.signup-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.signup-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 100%;
    max-width: 480px;
    background-color: white;
    box-shadow: -4px 0 6px rgba(0, 0, 0, 0.1);
    z-index: 70;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

@media (min-width: 640px) {
    .signup-drawer {
        max-width: 420px;
    }
}

.dark .signup-drawer {
    background-color: #111621;
    border-left: 1px solid #374151;
}

.signup-drawer.active {
    transform: translateX(0);
}

.signup-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e7ebf3;
    position: sticky;
    top: 0;
    background-color: white;
    z-index: 10;
}

.signup-drawer-header h2 {
    font-size: 1.125rem !important; /* text-lg - consistent across mobile and desktop */
    font-weight: 700 !important;
    letter-spacing: -0.025em;
    line-height: 1.25;
    margin-bottom: 0 !important; /* Override h2 margin */
}

/* Ensure signup drawer header h2 is excluded from responsive h2 rules */
@media (min-width: 768px) {
    .signup-drawer-header h2 {
        font-size: 1.125rem !important; /* Keep text-lg on desktop */
    }
}

@media (min-width: 1024px) {
    .signup-drawer-header h2 {
        font-size: 1.125rem !important; /* Keep text-lg on large screens */
    }
}

.dark .signup-drawer-header {
    background-color: #111621;
    border-bottom-color: #374151;
}

.signup-drawer-close {
    background: none;
    border: none;
    color: #0e121b;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}

.dark .signup-drawer-close {
    color: white;
}

.signup-drawer-close:hover {
    opacity: 0.7;
}

.signup-drawer-content {
    flex: 1;
    padding: 1.5rem 1.5rem;
    max-width: 100%;
    overflow-y: auto;
}

@media (min-width: 640px) {
    .signup-drawer-content {
        padding: 2rem 2rem;
    }
}

.signup-step {
    display: none;
}

.signup-step.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Step 1: Role Selection */
.signup-step h3 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.25;
    margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
    .signup-step h3 {
        font-size: 1.875rem;
    }
}

.signup-step > div:first-child {
    margin-bottom: 2rem;
}

.signup-step > div:first-child p {
    font-size: 0.875rem;
    line-height: 1.625;
    color: #6b7280;
}

.dark .signup-step > div:first-child p {
    color: #9ca3af;
}

.signup-role-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
}

@media (min-width: 640px) {
    .signup-role-grid {
        gap: 1.25rem;
    }
}

.signup-role-card {
    position: relative;
    display: flex;
    flex-direction: column;
    text-align: left;
    overflow: hidden;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    background-color: #f9fafb;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 180px;
    max-width: 100%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.dark .signup-role-card {
    border-color: #374151;
    background-color: #1f2937;
}

.signup-role-card:hover {
    border-color: #1754cf;
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(23, 84, 207, 0.15);
}

.dark .signup-role-card:hover {
    box-shadow: 0 4px 12px rgba(23, 84, 207, 0.3);
}

.signup-role-card:focus {
    outline: 2px solid #1754cf;
    outline-offset: 2px;
}

.signup-role-card:active {
    transform: translateY(-2px);
}

.signup-role-card .role-image {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.6;
}

.signup-role-card:hover .role-image {
    transform: scale(1.08);
    opacity: 0.7;
}

.signup-role-card .role-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.1), transparent);
    z-index: 10;
}

.signup-role-card .role-content {
    position: relative;
    padding: 1.5rem;
    z-index: 20;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 200px;
    justify-content: flex-end;
}

@media (min-width: 640px) {
    .signup-role-card .role-content {
        padding: 2rem;
        min-height: 220px;
    }
}

.signup-role-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111621;
    letter-spacing: -0.025em;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.dark .signup-role-card h3 {
    color: white;
}

.signup-role-card p {
    color: #4b5563;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.625;
    margin: 0;
}

.dark .signup-role-card p {
    color: #d1d5db;
}

.signup-role-card .role-arrow {
    color: #1754cf;
    opacity: 0;
    transform: translateX(-0.5rem);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.25rem;
}

.dark .signup-role-card .role-arrow {
    color: #60a5fa;
}

.signup-role-card:hover .role-arrow {
    opacity: 1;
    transform: translateX(0);
}

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

@media (min-width: 640px) {
    .signup-form {
        max-width: 500px;
    }
}

.signup-form-group {
    margin-bottom: 1rem;
}

#signup-step-3 .signup-form-group {
    margin-bottom: 1rem;
}

#signup-step-3 .mb-5 {
    margin-bottom: 1.25rem !important;
}

#signup-step-3 .mb-4 {
    margin-bottom: 1rem !important;
}

#signup-step-3 .mb-3 {
    margin-bottom: 0.75rem !important;
}

#signup-step-3 .mb-2 {
    margin-bottom: 0.5rem !important;
}

#signup-step-3 .mb-1\.5 {
    margin-bottom: 0.375rem !important;
}

#signup-step-3 .mb-1 {
    margin-bottom: 0.25rem !important;
}

#signup-step-3 h3 {
    font-size: 1.25rem !important;
    margin-bottom: 0.375rem !important;
    line-height: 1.3 !important;
}

@media (min-width: 768px) {
    #signup-step-3 h3 {
        font-size: 1.5rem !important;
    }
}

#signup-step-3 .text-xs {
    font-size: 0.75rem !important;
    line-height: 1.4 !important;
}

#signup-step-3 .signup-form-label {
    margin-bottom: 0.5rem !important;
    font-size: 0.6875rem !important;
    letter-spacing: 0.05em !important;
}

#signup-step-3 .signup-form-input {
    padding: 0.625rem 0.875rem !important;
    font-size: 0.875rem !important;
}

.signup-form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    letter-spacing: 0.01em;
}

.dark .signup-form-label {
    color: #d1d5db;
}

.signup-form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1.5px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 1rem;
    background-color: white;
    color: #111621;
    transition: all 0.2s;
    box-sizing: border-box;
}

.dark .signup-form-input {
    background-color: #1f2937;
    border-color: #4b5563;
    color: white;
}

.signup-form-input::placeholder {
    color: #9ca3af;
}

.dark .signup-form-input::placeholder {
    color: #6b7280;
}

.signup-form-input:focus {
    outline: none;
    border-color: #1754cf;
    box-shadow: 0 0 0 3px rgba(23, 84, 207, 0.1);
}

.dark .signup-form-input:focus {
    box-shadow: 0 0 0 3px rgba(23, 84, 207, 0.2);
}

.signup-button {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background-color: #1754cf;
    color: white;
    font-weight: 700;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
    margin-top: 0.5rem;
    box-shadow: 0 2px 4px rgba(23, 84, 207, 0.2);
}

.signup-button:hover {
    background-color: #1240a0;
    box-shadow: 0 4px 8px rgba(23, 84, 207, 0.3);
    transform: translateY(-1px);
}

.signup-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(23, 84, 207, 0.2);
}

.signup-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.signup-back-button {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 0.5rem 0;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.5;
    transition: all 0.2s;
    margin-bottom: 0;
    border-radius: 0.375rem;
}

#signup-step-3 .signup-back-button {
    margin-bottom: 0;
}

.signup-back-button .material-symbols-outlined {
    font-size: 1.125rem;
    line-height: 1;
    vertical-align: baseline;
}

.signup-back-button span:not(.material-symbols-outlined) {
    line-height: 1.5;
    vertical-align: baseline;
}

.signup-back-button:hover {
    color: #1754cf;
    background-color: #f3f4f6;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.dark .signup-back-button {
    color: #9ca3af;
}

.dark .signup-back-button:hover {
    color: #60a5fa;
    background-color: #1f2937;
}

/* Continue without account link */
#continue-without-account {
    display: inline-block;
    margin-top: 2rem;
    padding: 0.75rem 1rem;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

.dark #continue-without-account {
    color: #9ca3af;
}

#continue-without-account:hover {
    color: #111621;
    background-color: #f3f4f6;
}

.dark #continue-without-account:hover {
    color: white;
    background-color: #1f2937;
}

/* Prevent body scroll when signup drawer is open */
body.signup-drawer-open {
    overflow: hidden;
}

/* Skip preferences button alignment */
#skip-preferences {
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.5;
    padding: 0.5rem 0;
    vertical-align: baseline;
    display: inline-block;
}

/* Preferences Form Styles */
.preferences-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

@media (min-width: 640px) {
    .preferences-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.5rem;
    }
}

.preference-checkbox {
    cursor: pointer;
    position: relative;
}

.preference-checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.preference-checkbox-label {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.375rem;
    border: 1px solid #d1d5db;
    background-color: white;
    padding: 0.375rem 0.25rem;
    text-align: center;
    font-size: 0.6875rem;
    font-weight: 500;
    color: #0e121b;
    transition: all 0.2s ease;
    line-height: 1.2;
    min-height: 2rem;
}

.dark .preference-checkbox-label {
    border-color: #243047;
    background-color: #1a2130;
    color: #d1d5db;
}

.preference-checkbox-label:hover {
    border-color: #9ca3af;
    background-color: #f9fafb;
}

.dark .preference-checkbox-label:hover {
    border-color: #4b5563;
    background-color: #212836;
}

.preference-checkbox input:checked + .preference-checkbox-label {
    border-color: #1754cf;
    background-color: rgba(23, 84, 207, 0.1);
    color: #1754cf;
    box-shadow: inset 0 0 0 1px rgba(23, 84, 207, 0.2);
}

.preference-checkbox:active .preference-checkbox-label {
    transform: scale(0.98);
}

.preferences-format-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.preference-format {
    display: inline-flex;
    cursor: pointer;
    align-items: center;
    gap: 0.5rem;
    border-radius: 9999px;
    border: 1px solid #d1d5db;
    padding: 0.4375rem 0.875rem;
    transition: all 0.2s ease;
    font-size: 0.8125rem;
    color: #0e121b;
}

.dark .preference-format {
    border-color: #243047;
    color: #d1d5db;
}

.preference-format:hover {
    background-color: #f9fafb;
    border-color: #9ca3af;
}

.dark .preference-format:hover {
    background-color: #212836;
    border-color: #4b5563;
}

.preference-format input:checked ~ span,
.preference-format:has(input:checked) {
    border-color: #1754cf;
    background-color: rgba(23, 84, 207, 0.1);
    color: #1754cf;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.preference-format:active {
    transform: scale(0.97);
}

.preference-tag {
    padding: 0.3125rem 0.625rem;
    font-size: 0.6875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    border: 1px solid #e5e7eb;
    color: #4b5563;
    background-color: white;
    transition: all 0.2s ease;
    cursor: pointer;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.dark .preference-tag {
    border-color: #243047;
    color: #9ca3af;
    background-color: #1a2130;
}

.preference-tag:hover {
    border-color: #9ca3af;
    color: #0e121b;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.dark .preference-tag:hover {
    border-color: #4b5563;
    color: #e5e7eb;
}

.preference-tag:active {
    transform: scale(0.95);
}

.preference-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.preference-toggle-switch {
    width: 2.75rem;
    height: 1.5rem;
    background-color: #d1d5db;
    border-radius: 9999px;
    position: relative;
    transition: background-color 0.2s ease;
}

.dark .preference-toggle-switch {
    background-color: #243047;
}

.preference-toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 1.25rem;
    height: 1.25rem;
    background-color: white;
    border-radius: 9999px;
    transition: transform 0.2s ease;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.1);
}

.preference-toggle input:checked + .preference-toggle-switch {
    background-color: #1754cf;
}

.preference-toggle input:checked + .preference-toggle-switch::after {
    transform: translateX(1.25rem);
}

/* Login Drawer Styles */
.login-drawer-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 60;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.login-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.login-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 100%;
    max-width: 420px;
    background-color: #ffffff;
    border-left: 1px solid #e7ebf3;
    box-shadow: -4px 0 6px rgba(0, 0, 0, 0.1);
    z-index: 70;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

@media (min-width: 768px) {
    .login-drawer {
        max-width: 420px;
    }
}

.dark .login-drawer {
    background-color: #111621;
    border-left: 1px solid #374151;
}

.login-drawer.active {
    transform: translateX(0);
}

.login-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e7ebf3;
    background-color: #ffffff;
}

.login-drawer-header h2 {
    font-size: 1.125rem !important; /* text-lg - consistent across mobile and desktop */
    font-weight: 700 !important;
    letter-spacing: -0.025em;
    line-height: 1.25;
    margin-bottom: 0 !important; /* Override h2 margin */
    color: #0e121b;
}

@media (min-width: 768px) {
    .login-drawer-header h2 {
        font-size: 1.125rem !important; /* Keep text-lg on desktop */
    }
}

@media (min-width: 1024px) {
    .login-drawer-header h2 {
        font-size: 1.125rem !important; /* Keep text-lg on large screens */
    }
}

.dark .login-drawer-header {
    background-color: #111621;
    border-bottom-color: #374151;
}

.dark .login-drawer-header h2 {
    color: white;
}

.login-drawer-close {
    background: none;
    border: none;
    color: #0e121b;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}

.dark .login-drawer-close {
    color: white;
}

.login-drawer-close:hover {
    opacity: 0.7;
}

.login-drawer-content {
    flex: 1;
    padding: 2rem 1.5rem;
    max-width: 100%;
    overflow-y: auto;
}

@media (min-width: 768px) {
    .login-drawer-content {
        padding: 2.5rem 2rem;
    }
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.login-form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.login-form-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #0e121b;
}

.dark .login-form-label {
    color: white;
}

.login-form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #e7ebf3;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background-color: #ffffff;
    color: #0e121b;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.dark .login-form-input {
    background-color: #161b26;
    border-color: #374151;
    color: white;
}

.login-form-input:focus {
    outline: none;
    border-color: #1754cf;
    box-shadow: 0 0 0 2px rgba(23, 84, 207, 0.1);
}

.login-button {
    width: 100%;
    padding: 0.75rem 1.5rem;
    background-color: #1754cf;
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s;
}

.login-button:hover {
    background-color: #1240a0;
}

.login-button:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(23, 84, 207, 0.3);
}

.login-recovery-link {
    text-align: center;
    margin-top: 0.5rem;
}

.login-recovery-link a {
    font-size: 0.75rem;
    color: #1754cf;
    text-decoration: none;
    transition: color 0.2s;
}

.login-recovery-link a:hover {
    color: #1240a0;
    text-decoration: underline;
}

.dark .login-recovery-link a {
    color: #4a90e2;
}

.dark .login-recovery-link a:hover {
    color: #6ba3f0;
}

/* Prevent body scroll when login drawer is open */
body.login-drawer-open {
    overflow: hidden;
}

/* Account Page Styles */
.account-section {
    scroll-margin-top: 6rem;
}

/* Account Navigation */
.account-nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #4e6797;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    text-decoration: none;
    background: transparent;
    border: none;
    width: 100%;
    cursor: pointer;
}

.account-nav-item:hover {
    background-color: #e7ebf3;
    color: #0e121b;
}

.dark .account-nav-item {
    color: #9ca3af;
}

.dark .account-nav-item:hover {
    background-color: #1a2130;
    color: white;
}

.account-nav-item.active {
    background-color: #e7ebf3;
    color: #0e121b;
    font-weight: 600;
}

.dark .account-nav-item.active {
    background-color: #1a2130;
    color: white;
}

.account-nav-item .material-symbols-outlined {
    font-size: 1.25rem;
}

/* Account Labels */
.account-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #4e6797;
    margin-bottom: 0.5rem;
}

.dark .account-label {
    color: #9ca3af;
}

/* Account Inputs - Use signup-form-input for consistency */
.account-section .signup-form-input {
    width: 100%;
}

.account-section .signup-form-input:disabled,
.account-input-disabled {
    background-color: #f6f6f8 !important;
    color: #4e6797 !important;
    cursor: not-allowed;
    border-color: #e7ebf3 !important;
}

.dark .account-section .signup-form-input:disabled,
.dark .account-input-disabled {
    background-color: #151a24 !important;
    color: #6b7280 !important;
    border-color: #374151 !important;
}

/* Account Buttons */
.account-button-primary {
    padding: 0.625rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    background-color: #0e121b;
    color: white;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.dark .account-button-primary {
    background-color: white;
    color: #0e121b;
}

.account-button-primary:hover {
    opacity: 0.9;
}

.account-button-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    background-color: transparent;
    color: #1754cf;
    border: 1px solid #1754cf;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.account-button-secondary:hover {
    background-color: #1754cf;
    color: white;
}

.account-button-danger {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #dc2626;
    background-color: transparent;
    border: 1px solid #fecaca;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.dark .account-button-danger {
    border-color: rgba(220, 38, 38, 0.3);
    background-color: rgba(220, 38, 38, 0.1);
}

.account-button-danger:hover {
    background-color: #fee2e2;
    border-color: #dc2626;
}

.dark .account-button-danger:hover {
    background-color: rgba(220, 38, 38, 0.2);
}

/* Account Cards */
.account-card {
    padding: 1.5rem;
    background-color: #f6f6f8;
    border: 1px solid #e7ebf3;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
}

.dark .account-card {
    background-color: #151a24;
    border-color: #374151;
}

.account-card-empty {
    padding: 3rem 2rem;
    background-color: #f6f6f8;
    border: 1px solid #e7ebf3;
    border-radius: 0.5rem;
    text-align: center;
}

.dark .account-card-empty {
    background-color: #151a24;
    border-color: #374151;
}

/* Account Tags */
.account-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    background-color: #e7ebf3;
    color: #0e121b;
    border-radius: 0.25rem;
}

.dark .account-tag {
    background-color: #374151;
    color: #e5e7eb;
}

/* Account Table */
.account-table-wrapper {
    overflow-x: auto;
}

.account-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.account-table thead {
    background-color: #e7ebf3;
}

.dark .account-table thead {
    background-color: #1a2130;
}

.account-table thead th {
    padding: 0.875rem 1.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #4e6797;
    text-align: left;
}

.dark .account-table thead th {
    color: #9ca3af;
}

.account-table tbody tr {
    border-bottom: 1px solid #e7ebf3;
    transition: background-color 0.2s ease;
}

.dark .account-table tbody tr {
    border-bottom-color: #374151;
}

.account-table tbody tr:hover {
    background-color: rgba(231, 235, 243, 0.5);
}

.dark .account-table tbody tr:hover {
    background-color: #1a2130;
}

.account-table tbody tr:last-child {
    border-bottom: none;
}

.account-table tbody td {
    padding: 1rem 1.5rem;
}

/* Account Toggle Switch */
.account-toggle {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.account-toggle input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.account-toggle-switch {
    position: relative;
    width: 2.5rem;
    height: 1.375rem;
    background-color: #e7ebf3;
    border-radius: 9999px;
    transition: background-color 0.2s ease;
}

.dark .account-toggle-switch {
    background-color: #374151;
}

.account-toggle input:checked ~ .account-toggle-switch {
    background-color: #1754cf;
}

.account-toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 1.125rem;
    height: 1.125rem;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.account-toggle input:checked ~ .account-toggle-switch::after {
    transform: translateX(1.125rem);
}

/* Account Page Layout */
.account-page-header {
    margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
    .account-page-header {
        margin-bottom: 3rem;
    }
}

.account-page-title {
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .account-page-title {
        font-size: 2.25rem;
    }
}

.account-page-description {
    font-size: 0.875rem;
    color: #4e6797;
}

.dark .account-page-description {
    color: #9ca3af;
}

.account-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .account-layout {
        grid-template-columns: repeat(12, 1fr);
        gap: 3rem;
    }
}

.account-sidebar {
    grid-column: span 3;
}

.account-main {
    grid-column: span 9;
}

.account-sidebar-nav {
    position: sticky;
    top: 6rem;
}

.account-content {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.account-section-header {
    margin-bottom: 2rem;
}

.account-section-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

@media (min-width: 768px) {
    .account-section-title {
        font-size: 1.5rem;
    }
}

.account-section-description {
    font-size: 0.875rem;
    color: #4e6797;
}

.dark .account-section-description {
    color: #9ca3af;
}

.account-section-header-flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.account-form-group {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.account-form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: start;
}

@media (min-width: 768px) {
    .account-form-grid {
        grid-template-columns: repeat(2, 1fr);
        align-items: start;
    }
}

.account-form-field {
    display: flex;
    flex-direction: column;
}

.account-form-field .signup-form-label {
    margin-bottom: 0.5rem;
}

.account-form-field .signup-form-input {
    width: 100%;
}

.account-avatar-upload-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
    gap: 0.75rem;
}

.account-avatar-upload-button {
    position: relative;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.account-avatar-upload-button:hover {
    transform: scale(1.05);
}

.account-avatar-large {
    width: 5rem;
    height: 5rem;
    border-radius: 9999px;
    background-color: #1754cf;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 500;
    color: white;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.account-avatar-upload-button:hover .account-avatar-large {
    opacity: 0.9;
}

.account-avatar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 9999px;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.account-avatar-upload-button:hover .account-avatar-overlay {
    opacity: 1;
}

.account-avatar-upload-icon {
    color: white;
    font-size: 1.5rem;
}

.account-avatar-hint {
    font-size: 0.75rem;
    color: #4e6797;
    margin: 0;
}

.dark .account-avatar-hint {
    color: #9ca3af;
}

.account-password-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.account-form-actions {
    padding-top: 1rem;
    display: flex;
    justify-content: flex-end;
}

.account-preferences-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 768px) {
    .account-preferences-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.account-card-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.account-card-icon {
    color: #1754cf;
    font-size: 1.25rem;
}

.account-card-title {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.account-card-content {
    font-size: 0.875rem;
    color: #4e6797;
    line-height: 1.625;
}

.dark .account-card-content {
    color: #9ca3af;
}

.account-tags-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.account-history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.account-history-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.account-toggle-label {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.account-toggle-label-text {
    margin-left: 0.5rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: #4e6797;
}

.dark .account-toggle-label-text {
    color: #9ca3af;
}

.account-clear-button {
    font-size: 0.75rem;
    color: #ef4444;
    font-weight: 500;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.account-clear-button:hover {
    color: #dc2626;
}

.account-table-card {
    overflow: hidden;
    padding: 0;
}

.account-table-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e7ebf3;
}

.dark .account-table-footer {
    border-top-color: #374151;
}

.account-table-footer-button {
    font-size: 0.75rem;
    text-align: center;
    width: 100%;
    color: #4e6797;
    font-weight: 500;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.account-table-footer-button:hover {
    color: #0e121b;
}

.dark .account-table-footer-button {
    color: #9ca3af;
}

.dark .account-table-footer-button:hover {
    color: white;
}

.account-payment-methods {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.account-payment-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.account-payment-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.account-payment-logo {
    width: 3rem;
    height: 2rem;
    background-color: #e7ebf3;
    border-radius: 0.375rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dark .account-payment-logo {
    background-color: #374151;
}

.account-payment-logo-text {
    font-size: 0.625rem;
    font-weight: 700;
    color: #4e6797;
}

.dark .account-payment-logo-text {
    color: #9ca3af;
}

.account-payment-details {
    display: flex;
    flex-direction: column;
}

.account-payment-name {
    font-size: 0.875rem;
    font-weight: 500;
}

.account-payment-expiry {
    font-size: 0.75rem;
    color: #4e6797;
}

.dark .account-payment-expiry {
    color: #6b7280;
}

.account-payment-delete {
    color: #4e6797;
    opacity: 0;
    transition: all 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
}

.dark .account-payment-delete {
    color: #9ca3af;
}

.account-card.group:hover .account-payment-delete {
    opacity: 1;
}

.account-payment-delete:hover {
    color: #ef4444;
}

.account-icon-small {
    font-size: 18px;
}

.account-icon-medium {
    font-size: 20px;
}

.account-icon-large {
    font-size: 24px;
}

.account-payment-note {
    font-size: 0.75rem;
    color: #4e6797;
    font-style: italic;
    margin-top: 0.75rem;
}

.dark .account-payment-note {
    color: #6b7280;
}

.account-empty-icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 9999px;
    background-color: #e7ebf3;
    margin-bottom: 1rem;
}

.dark .account-empty-icon-wrapper {
    background-color: #374151;
}

.account-empty-icon {
    color: #4e6797;
    font-size: 1.5rem;
}

.dark .account-empty-icon {
    color: #6b7280;
}

.account-empty-title {
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.account-empty-description {
    font-size: 0.75rem;
    color: #4e6797;
    margin-bottom: 1rem;
}

.dark .account-empty-description {
    color: #6b7280;
}

.account-empty-link {
    font-size: 0.875rem;
    color: #1754cf;
    font-weight: 500;
    text-decoration: none;
    transition: text-decoration 0.2s ease;
}

.account-empty-link:hover {
    text-decoration: underline;
}

.account-delete-section {
    padding-top: 2rem;
    border-top: 1px solid #e7ebf3;
}

.dark .account-delete-section {
    border-top-color: #374151;
}

.account-delete-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 768px) {
    .account-delete-wrapper {
        flex-direction: row;
        align-items: flex-start;
        justify-content: space-between;
    }
}

.account-delete-content {
    flex: 1;
}

.account-delete-title {
    font-size: 0.875rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.account-delete-description {
    font-size: 0.75rem;
    color: #4e6797;
    line-height: 1.625;
    max-width: 28rem;
}

.dark .account-delete-description {
    color: #6b7280;
}

.account-nav-divider {
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid #e7ebf3;
}

.dark .account-nav-divider {
    border-top-color: #374151;
}

.account-nav-signout {
    color: #dc2626;
    width: 100%;
    text-align: left;
}

.dark .account-nav-signout {
    color: #f87171;
}

.account-nav-signout:hover {
    color: #b91c1c;
    background-color: transparent;
}

.dark .account-nav-signout:hover {
    color: #fca5a5;
}

.account-edit-link {
    font-size: 0.875rem;
    color: #1754cf;
    font-weight: 500;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.account-edit-link:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.account-change-password-link {
    font-size: 0.75rem;
    color: #1754cf;
    font-weight: 500;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.account-change-password-link:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.account-table-cell-artist {
    font-weight: 500;
}

.account-table-cell-release {
    color: #4e6797;
}

.dark .account-table-cell-release {
    color: #9ca3af;
}

.account-table-cell-date {
    text-align: right;
    color: #4e6797;
    font-size: 0.75rem;
}

.dark .account-table-cell-date {
    color: #6b7280;
}

.account-table-header-right {
    text-align: right;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .account-section {
        scroll-margin-top: 4rem;
    }

    .account-nav-item {
        font-size: 0.8125rem;
        padding: 0.5rem 0.75rem;
    }

    .account-sidebar-nav {
        position: static;
    }
}
