:root {
    color-scheme: light dark;
    --color-bg: #0e1419;
    --color-surface: rgba(24, 33, 44, 0.88);
    --color-card: rgba(28, 38, 49, 0.95);
    --color-border: rgba(255, 255, 255, 0.12);
    --color-text: #f6f8fb;
    --color-muted: rgba(236, 240, 246, 0.85); /* Lightened from 0.75 for better readability */
    --color-primary: #5c7cfa;
    --color-primary-soft: rgba(92, 124, 250, 0.16);
    --color-accent: #6ee7b7;
    --color-danger: #f87171;

    /* Aliases for consistency across pages */
    --text-secondary: rgba(236, 240, 246, 0.85); /* Lighter than before (was 0.75) */
    --card-bg: var(--color-card);
    --border-color: var(--color-border);
    --danger-color: var(--color-danger);
    
    /* Enhanced spacing system */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    
    /* Border radius */
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    
    /* Enhanced shadows with more depth */
    --shadow-soft: 0 12px 38px rgba(10, 15, 24, 0.42);
    --shadow-card: 0 18px 55px rgba(10, 15, 24, 0.48);
    --shadow-glow: 0 0 32px rgba(92, 124, 250, 0.2);
    --shadow-hover: 0 20px 60px rgba(10, 15, 24, 0.55);
    
    /* Transitions */
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    
    font-family: 'Manrope', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Improved focus states for accessibility */
*:focus {
    outline: none;
}

*:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 3px;
    border-radius: 4px;
}

body {
    margin: 0;
    background: radial-gradient(circle at top, rgba(92, 124, 250, 0.08), transparent 55%), #0b1016;
    color: var(--color-text);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

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

.container {
    width: min(1100px, 92%);
    margin: 0 auto;
}

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(18, 27, 36, 0.88);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: background var(--transition-base), border-color var(--transition-base);
}

.header-bar {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.4rem 0;
    flex-wrap: wrap;
}

.header-bar .branding {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex: 0 1 auto;
    min-width: 200px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    transition: transform var(--transition-fast);
}

.brand:hover {
    transform: translateY(-1px);
}

.brand-mark {
    display: block;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(92, 124, 250, 0.25);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.brand:hover .brand-mark {
    transform: scale(1.05);
    box-shadow: 0 8px 28px rgba(92, 124, 250, 0.4);
}

.tagline {
    font-size: 0.85rem;
    color: var(--color-muted);
    margin-top: 2px;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(27, 37, 48, 0.85);
    padding: 0.35rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex: 0 1 320px;
    margin-left: auto;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.header-search:focus-within {
    border-color: rgba(92, 124, 250, 0.5);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.header-search input[type="search"] {
    flex: 1 1 auto;
    min-width: 160px;
    padding: 0.55rem 0.75rem;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--color-text);
    font-size: 0.95rem;
}

.header-search input[type="search"]::placeholder {
    color: var(--color-muted);
    opacity: 0.6;
}

.header-search button {
    padding: 0.6rem 0.9rem;
    border: none;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--color-primary), #8338ec);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.header-search button:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: var(--shadow-soft);
}

.header-search button:active {
    transform: translateY(0) scale(0.98);
}

.primary-nav ul {
    list-style: none;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
    padding: 0;
    margin: 0;
}


.primary-nav a {
    padding: 0.65rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    color: var(--color-muted);
    transition: all var(--transition-fast);
    position: relative;
}

.primary-nav a:hover,
.primary-nav a:focus {
    color: #fff;
    background: rgba(92, 124, 250, 0.12);
    transform: translateY(-1px);
}

.primary-nav .cta {
    color: #fff;
    background: linear-gradient(135deg, var(--color-primary), #7c3aed);
    box-shadow: 0 12px 25px rgba(94, 123, 250, 0.3);
}








.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.primary-nav .cta:hover {
    box-shadow: 0 16px 32px rgba(94, 123, 250, 0.4);
    transform: translateY(-2px);
}

.user-menu {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.user-menu .avatar {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(92, 124, 250, 0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--color-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.user-menu .avatar:hover {
    background: rgba(92, 124, 250, 0.3);
    transform: scale(1.05);
}

/* Prevent horizontal scroll on mobile */
html {
    overflow-x: hidden;
    max-width: 100%;
}

body {
    overflow-x: hidden;
    max-width: 100%;
    position: relative;
}

/* Mobile menu toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: auto;
    z-index: 110;
    position: relative;
    pointer-events: auto;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--color-text);
    border-radius: 2px;
    transition: all 0.3s ease;
}

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

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

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

/* Mobile menu overlay */
.mobile-overlay {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 50;
    pointer-events: none;
}

.mobile-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.user-dropdown {
    position: absolute;
    top: calc(100% - 0.2rem);
    right: 0;
    background: var(--color-card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    padding: 1rem;
    display: block;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translate(calc(-100% + 38px), 6px);
    pointer-events: none;
    transition: opacity var(--transition-fast), transform var(--transition-fast), visibility var(--transition-fast);
    z-index: 20;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.user-menu:hover .user-dropdown,
.user-menu:focus-within .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.user-dropdown a,
.user-dropdown span {
    display: block;
    color: var(--color-muted);
    padding: 0.45rem 0;
    transition: color var(--transition-fast);
}

.user-dropdown a:hover {
    color: #fff;
}

.flash-wrapper {
    padding: 0.5rem 0 0;
}

.flash {
    border-radius: var(--radius-sm);
    padding: 0.85rem 1.1rem;
    margin-bottom: 0.6rem;
    background: rgba(92, 124, 250, 0.08);
    border: 1px solid rgba(92, 124, 250, 0.25);
    color: #fff;
    font-weight: 500;
    animation: slideIn 0.3s ease-out;
}

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

.flash-warning {
    background: rgba(251, 191, 36, 0.15);
    border-color: rgba(251, 191, 36, 0.4);
    color: #facc15;
}

.flash-success {
    background: rgba(110, 231, 183, 0.12);
    border-color: rgba(110, 231, 183, 0.38);
    color: var(--color-accent);
}

main.container {
    flex: 1;
    padding: var(--space-xl) 0 var(--space-2xl);
    width: min(1100px, 92%);
}

.hero {
    display: grid;
    gap: var(--space-lg);
    padding: 3.5rem;
    background: linear-gradient(135deg, rgba(92, 124, 250, 0.18), rgba(17, 24, 39, 0.92));
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(92, 124, 250, 0.2);
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(110, 231, 183, 0.18), transparent 42%);
    pointer-events: none;
}

.hero h1 {
    font-size: clamp(2.2rem, 3.6vw, 3.4rem);
    margin: 0;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.hero p {
    margin: var(--space-sm) 0 var(--space-lg);
    color: rgba(243, 245, 249, 0.78);
    font-size: 1.05rem;
}

.hero-actions {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

.section {
    margin-top: 3.5rem;
    display: grid;
    gap: var(--space-lg);
}

.section h2 {
    margin: 0;
    font-size: 1.6rem;
    letter-spacing: -0.01em;
}

.section-subheading {
    margin: var(--space-lg) 0 var(--space-sm);
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(243, 245, 249, 0.85);
}

.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.radio-group label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 500;
    color: rgba(243, 245, 249, 0.75);
    cursor: pointer;
    transition: color var(--transition-fast);
}

.radio-group label:hover {
    color: rgba(243, 245, 249, 0.95);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    padding: 0.85rem 1.6rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    min-height: 44px;
    min-width: 44px;
}

.btn-small {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
    min-height: auto;
    min-width: auto;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.btn:hover::before {
    opacity: 1;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), #a855f7);
    color: #fff;
    box-shadow: 0 15px 35px rgba(92, 124, 250, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 20px 45px rgba(92, 124, 250, 0.45);
}

.btn-primary:active {
    transform: translateY(0) scale(0.98);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-danger {
    background: rgba(248, 113, 113, 0.18);
    color: var(--color-danger);
    border: 1px solid rgba(248, 113, 113, 0.3);
}

.btn-danger:hover {
    background: rgba(248, 113, 113, 0.25);
    border-color: rgba(248, 113, 113, 0.4);
    transform: translateY(-2px);
}

.btn.copied {
    background: rgba(110, 231, 183, 0.18);
    color: var(--color-accent);
    border-color: rgba(110, 231, 183, 0.35);
    animation: pulse 0.5s ease-out;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.membership-note {
    margin: var(--space-sm) 0;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(92, 124, 250, 0.12);
    border: 1px solid rgba(92, 124, 250, 0.22);
    color: rgba(243, 245, 249, 0.9);
    font-size: 0.9rem;
}

.membership-note a {
    color: #c4d4ff;
    text-decoration: underline;
    transition: color var(--transition-fast);
}

.membership-note a:hover {
    color: #e0e9ff;
}

.membership-note.is-premium {
    background: rgba(110, 231, 183, 0.16);
    border-color: rgba(110, 231, 183, 0.35);
    color: rgba(226, 252, 239, 0.95);
}

.premium-link {
    color: #facc15;
    font-weight: 600;
    transition: all var(--transition-fast);
}

.premium-link:hover {
    color: #ffe066;
    background: rgba(250, 204, 21, 0.18);
}

.premium-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fde68a;
    background: rgba(250, 204, 21, 0.15);
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
    border: 1px solid rgba(250, 204, 21, 0.4);
    margin-bottom: 0.35rem;
}

.grid {
    display: grid;
    gap: 1.6rem;
}

.grid-cols-3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.prompt-card {
    position: relative;
    background: linear-gradient(140deg, rgba(24, 33, 46, 0.96), rgba(16, 23, 33, 0.92));
    border-radius: var(--radius-lg);
    padding: 1.8rem 2.15rem 1.95rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-soft);
    transition: all var(--transition-base);
    will-change: transform;
}

.prompt-card::before {
    content: none;
}

.prompt-card:hover {
    transform: translateY(-4px);
    border-color: rgba(92, 124, 250, 0.55);
    box-shadow: var(--shadow-hover);
}



.prompt-card.is-premium {
    border-color: rgba(250, 204, 21, 0.42);
    background: linear-gradient(140deg, rgba(24, 33, 46, 0.96), rgba(16, 23, 33, 0.92));
}

.prompt-card.is-premium::before {
    content: none;
}

.prompt-info-top {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
    margin: 0 0 var(--space-sm);
    padding: 0.55rem 1rem;
    background: rgba(92, 124, 250, 0.18);
    border: 1px solid rgba(92, 124, 250, 0.22);
    border-radius: var(--radius-sm);
}

.premium-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #facc15;
    background: rgba(250, 204, 21, 0.14);
    border: 1px solid rgba(250, 204, 21, 0.35);
    border-radius: 999px;
    padding: 0.25rem 0.75rem;
    transition: all var(--transition-fast);
}

.premium-pill:hover {
    background: rgba(250, 204, 21, 0.2);
    transform: scale(1.05);
}

.premium-pill.large {
    font-size: 0.8rem;
    padding: 0.35rem 0.95rem;
}

.premium-pill.small {
    font-size: 0.65rem;
    padding: 0.18rem 0.55rem;
    margin-left: 0.4rem;
}

.premium-pill.tiny {
    font-size: 0.6rem;
    padding: 0.15rem 0.45rem;
    margin-left: 0.4rem;
}

.premium-banner {
    margin: 1.2rem 0;
    padding: 1rem 1.2rem;
    background: rgba(250, 204, 21, 0.15);
    border: 1px solid rgba(250, 204, 21, 0.35);
    border-radius: var(--radius-md);
    color: rgba(252, 255, 232, 0.95);
}

.premium-banner a {
    color: #fef08a;
    text-decoration: underline;
    transition: color var(--transition-fast);
}

.premium-banner a:hover {
    color: #fffacd;
}

.premium-banner.compact {
    margin: 0.75rem 0;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
}

.premium-locked {
    background: rgba(21, 30, 40, 0.95);
    border: 1px dashed rgba(250, 204, 21, 0.45);
    border-radius: var(--radius-md);
    padding: 1.4rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    color: rgba(243, 245, 249, 0.85);
}

.prompt-admin-controls {
    margin-top: 1.8rem;
    padding: 1rem 1.2rem;
    border-radius: var(--radius-md);
    background: rgba(92, 124, 250, 0.12);
    border: 1px solid rgba(92, 124, 250, 0.22);
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.prompt-admin-controls h3 {
    margin: 0;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    color: rgba(243, 245, 249, 0.85);
}

.prompt-admin-controls .admin-inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.prompt-admin-controls label {
    font-weight: 600;
    font-size: 0.85rem;
    color: rgba(243, 245, 249, 0.75);
}

.prompt-admin-controls select,
.prompt-admin-controls input[type="text"] {
    background: rgba(12, 17, 23, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-sm);
    padding: 0.55rem 0.75rem;
    color: #fff;
    min-width: 160px;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.prompt-admin-controls select:focus,
.prompt-admin-controls input[type="text"]:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.prompt-admin-controls .admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.prompt-admin-controls .inline-form {
    display: inline-flex;
}

.prompt-card-main {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.2rem;
    align-items: flex-start;
}

.prompt-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.prompt-card.is-pending .category-badge {
    background: rgba(251, 191, 36, 0.22);
    color: #facc15;
}

.prompt-card.is-draft .category-badge {
    background: rgba(148, 163, 184, 0.22);
    color: rgba(226, 232, 240, 0.9);
}

.prompt-card .category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.16);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: all var(--transition-fast);
}

.prompt-card .category-badge:hover {
    background: rgba(92, 124, 250, 0.24);
    transform: scale(1.05);
}

.category-badge a {
    color: inherit;
}

.prompt-card h3 {
    margin: 0 0 var(--space-sm);
    font-size: 1.26rem;
    line-height: 1.3;
    background: linear-gradient(90deg, rgba(12, 18, 26, 0.78), rgba(16, 23, 33, 0.92));
    padding: 0.85rem 1.35rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
    transition: all var(--transition-fast);
}

.prompt-card h3:hover {
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.prompt-card h3 a {
    color: inherit;
    display: block;
}

.prompt-card p {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.95rem;
}

.vote-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    min-width: 3.5rem;
}

.vote-form {
    margin: 0;
}

.vote-button {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(10, 15, 21, 0.65);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
    transition: all var(--transition-base);
    will-change: transform;
}

.vote-button:hover {
    color: #fff;
    border-color: rgba(92, 124, 250, 0.45);
    box-shadow: 0 12px 24px rgba(92, 124, 250, 0.25);
    transform: translateY(-2px) scale(1.05);
}

.vote-button:active {
    transform: translateY(0) scale(0.95);
}

.vote-button.is-active {
    background: linear-gradient(135deg, var(--color-primary), #8b5cf6);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow: 0 14px 32px rgba(92, 124, 250, 0.35);
}

.vote-button.is-active:hover {
    box-shadow: 0 18px 40px rgba(92, 124, 250, 0.45);
}

.vote-score {
    font-weight: 700;
    font-size: 1.05rem;
    color: #fff;
}

.status-banner {
    margin: var(--space-sm) 0 var(--space-lg);
    padding: 1rem 1.2rem;
    border-radius: var(--radius-sm);
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.35);
    color: #facc15;
    font-weight: 600;
}

.meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
    color: rgba(243, 245, 249, 0.80); /* Lightened from 0.55 for better readability */
    font-size: 0.85rem; /* Increased from 0.82rem for better readability */
}

.meta-line strong {
    color: rgba(243, 245, 249, 0.95); /* Make version labels more prominent */
    font-weight: 600;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.tag {
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.14);
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.8rem;
    letter-spacing: 0.02em;
    transition: all var(--transition-fast);
}

.tag:hover {
    background: rgba(92, 124, 250, 0.22);
    transform: translateY(-1px);
}

.sidebar-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 1.6rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-soft);
}

.two-column {
    display: grid;
    gap: var(--space-lg);
}

.two-column-main {
    display: grid;
    gap: var(--space-md);
}

.prompt-detail {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2.2rem;
    box-shadow: var(--shadow-card);
}

.prompt-header {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.6rem;
    align-items: flex-start;
    margin-bottom: var(--space-md);
}

.prompt-header-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.prompt-detail pre {
    background: rgba(18, 27, 37, 0.92);
    border-radius: var(--radius-md);
    padding: 1.35rem 1.6rem;
    overflow-x: auto;
    white-space: pre-wrap;
    font-family: 'Fira Code', 'Source Code Pro', monospace;
    font-size: 0.95rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
}

.prompt-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2rem;
    font-size: 0.85rem;
    color: var(--color-muted);
    margin-bottom: var(--space-md);
}

.version-list {
    display: flex;
    gap: var(--space-xs);
    flex-wrap: wrap;
    margin-top: var(--space-sm);
}

.version-pill {
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.18);
    font-weight: 600;
    font-size: 0.8rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition-base);
}

.version-pill:hover {
    background: rgba(92, 124, 250, 0.25);
    transform: translateY(-1px);
}

.version-pill.is-active {
    background: linear-gradient(135deg, var(--color-primary), #8b5cf6);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 12px 28px rgba(92, 124, 250, 0.35);
}

.version-block {
    display: block;
}

.version-block:not(.is-active) {
    display: none;
}

.comment-list {
    display: grid;
    gap: var(--space-sm);
    margin: var(--space-lg) 0 0;
}

.comment {
    background: rgba(12, 17, 23, 0.9);
    border-radius: var(--radius-md);
    padding: 1rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.04);
    transition: border-color var(--transition-fast);
}

.comment:hover {
    border-color: rgba(255, 255, 255, 0.08);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    gap: var(--space-sm);
    color: var(--color-muted);
    font-size: 0.82rem;
    margin-bottom: 0.6rem;
}

.form-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 2.2rem;
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(255, 255, 255, 0.09);
}

.form-link {
    display: inline-block;
    margin-top: var(--space-xs);
    color: var(--color-primary);
    font-weight: 600;
    transition: color var(--transition-fast);
}

.form-link:hover {
    color: var(--color-accent);
}

.form-grid {
    display: grid;
    gap: 1.2rem;
}

.form-grid label {
    font-weight: 600;
    display: block;
    margin-bottom: 0.4rem;
}

.form-grid input,
.form-grid textarea,
.form-grid select {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(20, 29, 39, 0.94);
    color: var(--color-text);
    font-size: 0.95rem;
    transition: all var(--transition-fast);
}

.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
    outline: none;
}

.form-grid textarea {
    min-height: 160px;
    resize: vertical;
}

.input-hint {
    font-size: 0.78rem;
    color: var(--color-muted);
    margin-top: 0.3rem;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: var(--space-sm);
    margin-top: var(--space-md);
}

.inline-form {
    display: inline-flex;
}

.moderation .prompt-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.moderation .form-actions {
    justify-content: flex-start;
}

.prompt-review {
    margin-top: 0.8rem;
}

.prompt-review summary {
    cursor: pointer;
    color: var(--color-primary);
    font-weight: 600;
    transition: color var(--transition-fast);
}

.prompt-review summary:hover {
    color: var(--color-accent);
}

.prompt-review pre {
    margin-top: 0.6rem;
    background: rgba(10, 15, 21, 0.85);
    border-radius: var(--radius-sm);
    padding: var(--space-sm);
    border: 1px solid rgba(255, 255, 255, 0.08);
    max-height: 260px;
    overflow: auto;
    font-size: 0.9rem;
}

.list-page {
    display: grid;
    gap: var(--space-lg);
}

.filters-bar {
    background: rgba(14, 20, 26, 0.95);
    border-radius: var(--radius-lg);
    padding: 1.3rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: grid;
    gap: var(--space-sm);
}

.filters {
    display: grid;
    gap: var(--space-sm);
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.filters-submit {
    padding: 0.75rem 1.1rem;
    border-radius: var(--radius-sm);
    border: none;
    background: linear-gradient(135deg, var(--color-primary), #7c3aed);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-base);
}

.filters-submit:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: var(--shadow-soft);
}

.filters-submit:active {
    transform: translateY(0) scale(0.98);
}

.filters select {
    background: rgba(10, 15, 21, 0.9);
    color: var(--color-text);
    transition: all var(--transition-fast);
}

.filters input[type="search"] {
    background: rgba(10, 15, 21, 0.9);
    color: var(--color-text);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 0.7rem 0.85rem;
    font-size: 0.95rem;
    width: 100%;
}

.filters input[type="search"]::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

.filters input[type="search"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.filters select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-md);
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    margin-top: var(--space-md);
}

.pagination a {
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    transition: all var(--transition-fast);
}

.pagination a:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.leaderboard {
    display: grid;
    gap: var(--space-lg);
}

.leaderboard-card {
    background: rgba(14, 20, 26, 0.92);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow-soft);
}

.leaderboard-card h2 {
    margin-top: 0;
    margin-bottom: 1.2rem;
    font-size: 1.3rem;
}

.leaderboard-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.leaderboard-list li {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    align-items: center;
    gap: var(--space-sm);
    padding: 0.55rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background var(--transition-fast);
}

.leaderboard-list li:hover {
    background: rgba(255, 255, 255, 0.02);
}

.leaderboard-list li:last-child {
    border-bottom: none;
}

.leaderboard-list .rank {
    font-weight: 700;
    color: rgba(92, 124, 250, 0.85);
}

.leaderboard-list .score {
    font-weight: 600;
    color: rgba(110, 231, 183, 0.9);
}

.leaderboard-item .title {
    font-weight: 600;
}

.leaderboard-item .meta {
    display: block;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.leaderboard-item {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: var(--space-xs);
}

.leaderboard-item .title {
    grid-column: 1 / 3;
}

.leaderboard-item .meta {
    grid-column: 1 / 2;
}

.leaderboard-item .premium-pill {
    grid-column: 2 / 3;
    justify-self: end;
    margin: 0;
}

.category-block {
    margin-bottom: 1.4rem;
}

.category-block h3 {
    margin: var(--space-sm) 0 0.6rem;
    font-size: 1rem;
    color: rgba(243, 245, 249, 0.9);
}

.category-block ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-block li {
    display: flex;
    justify-content: space-between;
    padding: 0.4rem 0;
    color: rgba(243, 245, 249, 0.85);
    transition: background var(--transition-fast);
}

.category-block li:hover {
    background: rgba(255, 255, 255, 0.02);
}

.category-block li .score {
    color: rgba(110, 231, 183, 0.85);
}

.category-header {
    margin-bottom: var(--space-lg);
}

.category-header h1 {
    margin: 0;
    font-size: 2.1rem;
}

.category-leaderboards {
    display: grid;
    gap: var(--space-lg);
}

.category-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-soft);
    transition: all var(--transition-base);
}

.category-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.category-card.is-premium {
    border-color: rgba(250, 204, 21, 0.3);
    background: linear-gradient(150deg, rgba(250, 204, 21, 0.12), var(--color-card));
}

.category-card h2 {
    margin-top: 0;
    margin-bottom: var(--space-xs);
}

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

.category-grid ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-grid li {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.4rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    align-items: center;
    transition: background var(--transition-fast);
}

.category-grid li:hover {
    background: rgba(255, 255, 255, 0.02);
}

.category-grid li:last-child {
    border-bottom: none;
}

.category-grid .title {
    font-weight: 600;
}

.category-grid .meta {
    grid-column: 1 / -1;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.category-grid .score {
    color: rgba(110, 231, 183, 0.9);
    font-weight: 600;
}

.profile-portfolio {
    display: grid;
    gap: var(--space-lg);
}

.portfolio-header h1 {
    margin: 0;
    font-size: 2rem;
}

.portfolio-header p {
    margin: var(--space-xs) 0 0;
    color: var(--color-muted);
}

.site-footer {
    margin-top: auto;
    background: rgba(18, 27, 36, 0.88);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-lg);
    justify-content: space-between;
    padding: 2.5rem 0;
    color: var(--color-muted);
}

.footer-links {
    display: flex;
    gap: var(--space-md);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.75);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: #fff;
}

.footer-meta {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: var(--space-sm) 0;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

.membership-hero {
    margin: var(--space-xl) 0;
    padding: 2.8rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(150deg, rgba(92, 124, 250, 0.26), rgba(24, 35, 46, 0.95));
    border: 1px solid rgba(92, 124, 250, 0.38);
    box-shadow: var(--shadow-card);
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.membership-hero h1 {
    font-size: 2.25rem;
    margin-bottom: var(--space-sm);
}

.membership-hero p {
    font-size: 1.05rem;
    color: rgba(243, 245, 249, 0.8);
    max-width: 720px;
}

.membership-benefits {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--space-md);
    margin: 2.5rem 0;
}

.membership-benefits .benefit {
    background: rgba(26, 36, 47, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    box-shadow: var(--shadow-soft);
    transition: all var(--transition-base);
}

.membership-benefits .benefit:hover {
    transform: translateY(-2px);
    border-color: rgba(92, 124, 250, 0.3);
    box-shadow: var(--shadow-hover);
}

.membership-benefits h3 {
    margin-top: 0;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.membership-plans {
    margin: var(--space-xl) 0;
    text-align: center;
}

.membership-plans h2 {
    font-size: 1.8rem;
    margin-bottom: var(--space-lg);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--space-lg);
    align-items: stretch;
}

.pricing-card {
    background: linear-gradient(140deg, rgba(24, 35, 46, 0.96), rgba(92, 124, 250, 0.12));
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-lg);
    padding: 2.2rem 1.9rem;
    text-align: left;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    transition: all var(--transition-base);
}

.pricing-card:hover {
    transform: translateY(-4px);
    border-color: rgba(92, 124, 250, 0.4);
    box-shadow: var(--shadow-hover);
}

.pricing-card .price {
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: baseline;
    gap: var(--space-xs);
    color: #fff;
}

.pricing-card .currency {
    font-size: 1rem;
    color: rgba(243, 245, 249, 0.75);
}

.pricing-card .term {
    font-size: 0.85rem;
    font-weight: 500;
    color: rgba(243, 245, 249, 0.65);
}

.pricing-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    color: rgba(243, 245, 249, 0.8);
}

.pricing-card ul li::before {
    content: '•';
    margin-right: var(--space-xs);
    color: rgba(92, 124, 250, 0.6);
}

.membership-plans .btn {
    align-self: flex-start;
}

.membership-plans .membership-note {
    text-align: center;
    margin-top: var(--space-lg);
}

.membership-faq {
    margin: var(--space-xl) 0;
}

.membership-faq h2 {
    font-size: 1.6rem;
    margin-bottom: var(--space-md);
}

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

.faq-grid h3 {
    margin-top: 0;
    font-size: 1.1rem;
}

/* Loading skeleton states */
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255,255,255,0.05) 25%,
        rgba(255,255,255,0.1) 50%,
        rgba(255,255,255,0.05) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    :root {
        font-size: 15px;
    }

    .header-bar {
        flex-wrap: nowrap;
        position: relative;
        overflow: visible;
    }

    .mobile-menu-toggle {
        display: flex;
        min-width: 44px;
        min-height: 44px;
        justify-content: center;
        align-items: center;
    }

    .container {
        max-width: 100%;
        overflow-x: hidden;
    }

    .primary-nav {
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        max-width: 85vw;
        height: 100vh;
        background: var(--color-surface);
        backdrop-filter: blur(18px);
        padding: 5rem 1.5rem 2rem;
        overflow-y: auto;
        overflow-x: hidden;
        z-index: 100;
        border-left: 1px solid var(--color-border);
        -webkit-overflow-scrolling: touch;
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }

    .primary-nav.active {
        transform: translateX(0);
    }

    .primary-nav ul {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    .primary-nav li {
        width: 100%;
    }

    .primary-nav a {
        display: block;
        width: 100%;
        padding: 0.85rem 1rem;
        cursor: pointer;
        -webkit-tap-highlight-color: rgba(92, 124, 250, 0.2);
    }

    .user-menu {
        display: block;
        width: 100%;
    }

    .user-menu .user-dropdown {
        position: static;
        transform: none;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        box-shadow: none;
        background: transparent;
        border: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .user-menu .avatar {
        display: none;
    }

    .user-menu .user-dropdown a {
        display: block;
        width: 100%;
        padding: 0.85rem 1rem;
        color: var(--color-muted);
        background: none;
        border-radius: var(--radius-sm);
        cursor: pointer;
        -webkit-tap-highlight-color: rgba(92, 124, 250, 0.2);
    }

    .user-menu .user-dropdown a:hover {
        color: #fff;
        background: rgba(92, 124, 250, 0.12);
    }

    .user-menu .user-name,
    .user-menu .premium-chip {
        padding: 0.5rem 1rem;
        display: block;
        font-size: 0.875rem;
        opacity: 0.7;
    }

    .header-search {
        width: 100%;
        margin-left: 0;
    }

    /* Stack two-column layouts vertically on mobile */
    .two-column {
        grid-template-columns: 1fr !important;
        gap: var(--space-md);
    }

    /* Prompt pages: Main content comes first, sidebar second */
    .two-column .two-column-main {
        order: 1;
    }

    .two-column aside.sidebar-card {
        order: 2;
    }

    /* Profile page: Keep form (aside) first, prompts second */
    .two-column aside.form-card {
        order: 1;
    }

    .two-column section.two-column-main {
        order: 2;
    }

    /* Make prompt detail padding smaller on mobile */
    .prompt-detail {
        padding: 1.5rem;
    }

    .sidebar-card {
        padding: 1.5rem;
    }

    .form-card {
        padding: 1.5rem;
    }

    /* Stack grid layouts to single column on mobile */
    .grid {
        grid-template-columns: 1fr !important;
    }

    .grid-cols-2,
    .grid-cols-3 {
        grid-template-columns: 1fr !important;
    }

    /* Adjust vote stack on mobile */
    .vote-stack {
        min-width: 45px;
    }

    .vote-button {
        font-size: 1.2rem;
        padding: 0.4rem;
    }

    /* Better text sizing on mobile */
    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    /* Make code blocks scrollable on mobile */
    .prompt-text {
        font-size: 0.9rem;
        max-width: 100%;
        overflow-x: auto;
    }

    .hero {
        padding: 2.5rem;
    }

    .form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .prompt-card-main,
    .prompt-header {
        grid-template-columns: 1fr;
    }

    .vote-stack {
        flex-direction: row;
        justify-content: flex-start;
        min-width: 0;
    }

    .vote-stack .vote-score {
        order: 2;
    }

    .vote-button {
        width: 38px;
        height: 38px;
    }

    .leaderboard-card h2 {
        font-size: 1.1rem;
    }

    .leaderboard-list li {
        grid-template-columns: 24px 1fr auto;
        font-size: 0.85rem;
        gap: 0.4rem;
        padding: 0.6rem 0.5rem;
    }

    .leaderboard-list .rank {
        font-size: 0.8rem;
    }

    .leaderboard-list .score {
        justify-self: end;
        font-size: 0.8rem;
        white-space: nowrap;
    }

    .leaderboard-list .name {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .leaderboard-item .title {
        font-size: 0.85rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .leaderboard-item .meta {
        font-size: 0.7rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .membership-hero {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        padding: 2.2rem;
    }

    .membership-hero .hero-actions {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

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

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Light mode support */
@media (prefers-color-scheme: light) {
    :root {
        --color-bg: #f7f9fb;
        --color-text: #0f172a;
        --color-muted: #64748b;
        --color-card: #ffffff;
        --color-surface: #ffffff;
        --color-border: rgba(15, 23, 42, 0.08);
        --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.1);
        --shadow-card: 0 20px 60px rgba(15, 23, 42, 0.12);
        --shadow-hover: 0 24px 70px rgba(15, 23, 42, 0.15);
    }

    body {
        background: radial-gradient(circle at top, rgba(92, 124, 250, 0.12), transparent 55%), #eef2ff;
    }

    .site-header,
    .site-footer {
        background: rgba(255, 255, 255, 0.9);
    }

    .prompt-card,
    .prompt-detail,
    .form-card,
    .sidebar-card {
        border-color: rgba(15, 23, 42, 0.08);
    }

    .prompt-card:hover {
        border-color: rgba(92, 124, 250, 0.6);
    }

    .vote-button {
        background: rgba(15, 23, 42, 0.05);
        color: var(--color-muted);
        border-color: rgba(15, 23, 42, 0.12);
    }

    .vote-button.is-active {
        color: #fff;
    }

    .vote-score {
        color: var(--color-text);
    }

    .prompt-card.is-pending .category-badge {
        background: rgba(251, 191, 36, 0.18);
        color: #b45309;
    }

    .prompt-card.is-draft .category-badge {
        background: rgba(148, 163, 184, 0.18);
        color: #475569;
    }

    .status-banner {
        background: rgba(251, 191, 36, 0.15);
        border-color: rgba(217, 119, 6, 0.4);
        color: #b45309;
    }
}

/* Safe area insets for mobile devices with notches */
@supports (padding: max(0px)) {
    body {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
    }
    
    .site-header {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
    }
    
    .site-footer {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
        padding-bottom: max(0px, env(safe-area-inset-bottom));
    }
}:root {
    color-scheme: light dark;
    --color-bg: #0e1419;
    --color-surface: rgba(24, 33, 44, 0.88);
    --color-card: rgba(28, 38, 49, 0.95);
    --color-border: rgba(255, 255, 255, 0.12);
    --color-text: #f6f8fb;
    --color-muted: rgba(236, 240, 246, 0.68);
    --color-primary: #5c7cfa;
    --color-primary-soft: rgba(92, 124, 250, 0.16);
    --color-accent: #6ee7b7;
    --color-danger: #f87171;
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --shadow-soft: 0 12px 38px rgba(10, 15, 24, 0.42);
    --shadow-card: 0 18px 55px rgba(10, 15, 24, 0.48);
    font-family: 'Manrope', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: radial-gradient(circle at top, rgba(92, 124, 250, 0.08), transparent 55%), #0b1016;
    color: var(--color-text);
    font-size: 16px;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(1100px, 92%);
    margin: 0 auto;
}

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(18, 27, 36, 0.88);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.header-bar {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.4rem 0;
    flex-wrap: wrap;
}

.header-bar .branding {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex: 0 1 auto;
    min-width: 200px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.brand-mark {
    display: block;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(92, 124, 250, 0.25);
}

.tagline {
    font-size: 0.85rem;
    color: var(--color-muted);
    margin-top: 2px;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(27, 37, 48, 0.85);
    padding: 0.35rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex: 0 1 320px;
    margin-left: auto;
}

.header-search input[type="search"] {
    flex: 1 1 auto;
    min-width: 160px;
    padding: 0.55rem 0.75rem;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--color-text);
    font-size: 0.95rem;
}

.header-search button {
    padding: 0.6rem 0.9rem;
    border: none;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--color-primary), #8338ec);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.header-search button:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-soft);
}

.primary-nav ul {
    list-style: none;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
    padding: 0;
    margin: 0;
}

.primary-nav a {
    padding: 0.65rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    color: var(--color-muted);
    transition: background 0.2s ease, color 0.2s ease;
}

.primary-nav a:hover,
.primary-nav a:focus {
    color: #fff;
    background: rgba(92, 124, 250, 0.12);
}

.primary-nav .cta {
    color: #fff;
    background: linear-gradient(135deg, var(--color-primary), #7c3aed);
    box-shadow: 0 12px 25px rgba(94, 123, 250, 0.3);
}

.user-menu {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.user-menu .avatar {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(92, 124, 250, 0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--color-primary);
}

.user-dropdown {
    position: absolute;
    top: calc(100% - 0.2rem);
    right: 0;
    background: var(--color-card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    padding: 1rem;
    display: block;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translate(calc(-100% + 38px), 6px);
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
    z-index: 20;
}

.user-menu:hover .user-dropdown,
.user-menu:focus-within .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.user-dropdown a,
.user-dropdown span {
    display: block;
    color: var(--color-muted);
    padding: 0.45rem 0;
}

.user-dropdown a:hover {
    color: #fff;
}

.flash-wrapper {
    padding: 0.5rem 0 0;
}

.flash {
    border-radius: var(--radius-sm);
    padding: 0.85rem 1.1rem;
    margin-bottom: 0.6rem;
    background: rgba(92, 124, 250, 0.08);
    border: 1px solid rgba(92, 124, 250, 0.25);
    color: #fff;
    font-weight: 500;
}

.flash-warning {
    background: rgba(251, 191, 36, 0.15);
    border-color: rgba(251, 191, 36, 0.4);
    color: #facc15;
}

.flash-success {
    background: rgba(110, 231, 183, 0.12);
    border-color: rgba(110, 231, 183, 0.38);
    color: var(--color-accent);
}

main.container {
    flex: 1;
    padding: 3rem 0 4rem;
    width: min(1100px, 92%);
}

.hero {
    display: grid;
    gap: 2rem;
    padding: 3.5rem;
    background: linear-gradient(135deg, rgba(92, 124, 250, 0.18), rgba(17, 24, 39, 0.92));
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    position: relative;
    overflow: hidden;
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(110, 231, 183, 0.18), transparent 42%);
    pointer-events: none;
}

.hero h1 {
    font-size: clamp(2.2rem, 3.6vw, 3.4rem);
    margin: 0;
    line-height: 1.1;
}

.hero p {
    margin: 1rem 0 2rem;
    color: rgba(243, 245, 249, 0.78);
    font-size: 1.05rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.section {
    margin-top: 3.5rem;
    display: grid;
    gap: 2rem;
}

.section h2 {
    margin: 0;
    font-size: 1.6rem;
}

.section-subheading {
    margin: 2rem 0 1rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(243, 245, 249, 0.85);
}

.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.radio-group label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 500;
    color: rgba(243, 245, 249, 0.75);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.6rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), #a855f7);
    color: #fff;
    box-shadow: 0 15px 35px rgba(92, 124, 250, 0.35);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-danger {
    background: rgba(248, 113, 113, 0.18);
    color: var(--color-danger);
    border: 1px solid rgba(248, 113, 113, 0.3);
}

.btn:hover {
    transform: translateY(-2px);
}

.btn.copied {
    background: rgba(110, 231, 183, 0.18);
    color: var(--color-accent);
    border-color: rgba(110, 231, 183, 0.35);
}

.membership-note {
    margin: 1rem 0;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(92, 124, 250, 0.12);
    border: 1px solid rgba(92, 124, 250, 0.22);
    color: rgba(243, 245, 249, 0.9);
    font-size: 0.9rem;
}

.membership-note a {
    color: #c4d4ff;
    text-decoration: underline;
}

.membership-note.is-premium {
    background: rgba(110, 231, 183, 0.16);
    border-color: rgba(110, 231, 183, 0.35);
    color: rgba(226, 252, 239, 0.95);
}

.premium-link {
    color: #facc15;
    font-weight: 600;
}

.premium-link:hover {
    color: #ffe066;
    background: rgba(250, 204, 21, 0.18);
}

.premium-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fde68a;
    background: rgba(250, 204, 21, 0.15);
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
    border: 1px solid rgba(250, 204, 21, 0.4);
    margin-bottom: 0.35rem;
}

.grid {
    display: grid;
    gap: 1.6rem;
}

.grid-cols-3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}


.prompt-card {
    position: relative;
    background: linear-gradient(140deg, rgba(24, 33, 46, 0.96), rgba(16, 23, 33, 0.92));
    border-radius: var(--radius-lg);
    padding: 1.8rem 2.15rem 1.95rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.prompt-card:hover {
    transform: translateY(-4px);
    border-color: rgba(92, 124, 250, 0.55);
}



.prompt-card.is-premium {
    border-color: rgba(250, 204, 21, 0.42);
    background: linear-gradient(140deg, rgba(24, 33, 46, 0.96), rgba(16, 23, 33, 0.92));
}

.prompt-info-top {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
    margin: 0 0 1rem;
    padding: 0.55rem 1rem;
    background: rgba(92, 124, 250, 0.18);
    border: 1px solid rgba(92, 124, 250, 0.22);
    border-radius: var(--radius-sm);
}

.premium-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #facc15;
    background: rgba(250, 204, 21, 0.14);
    border: 1px solid rgba(250, 204, 21, 0.35);
    border-radius: 999px;
    padding: 0.25rem 0.75rem;
}

.premium-pill.large {
    font-size: 0.8rem;
    padding: 0.35rem 0.95rem;
}

.premium-pill.small {
    font-size: 0.65rem;
    padding: 0.18rem 0.55rem;
    margin-left: 0.4rem;
}

.premium-pill.tiny {
    font-size: 0.6rem;
    padding: 0.15rem 0.45rem;
    margin-left: 0.4rem;
}

.premium-banner {
    margin: 1.2rem 0;
    padding: 1rem 1.2rem;
    background: rgba(250, 204, 21, 0.15);
    border: 1px solid rgba(250, 204, 21, 0.35);
    border-radius: var(--radius-md);
    color: rgba(252, 255, 232, 0.95);
}

.premium-banner a {
    color: #fef08a;
    text-decoration: underline;
}

.premium-banner.compact {
    margin: 0.75rem 0;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
}

.premium-locked {
    background: rgba(21, 30, 40, 0.95);
    border: 1px dashed rgba(250, 204, 21, 0.45);
    border-radius: var(--radius-md);
    padding: 1.4rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: rgba(243, 245, 249, 0.85);
}

.prompt-admin-controls {
    margin-top: 1.8rem;
    padding: 1rem 1.2rem;
    border-radius: var(--radius-md);
    background: rgba(92, 124, 250, 0.12);
    border: 1px solid rgba(92, 124, 250, 0.22);
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.prompt-admin-controls h3 {
    margin: 0;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    color: rgba(243, 245, 249, 0.85);
}

.prompt-admin-controls .admin-inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.prompt-admin-controls label {
    font-weight: 600;
    font-size: 0.85rem;
    color: rgba(243, 245, 249, 0.75);
}

.prompt-admin-controls select,
.prompt-admin-controls input[type="text"] {
    background: rgba(12, 17, 23, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-sm);
    padding: 0.55rem 0.75rem;
    color: #fff;
    min-width: 160px;
}

.prompt-admin-controls .admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.prompt-admin-controls .inline-form {
    display: inline-flex;
}

.prompt-card-main {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.2rem;
    align-items: flex-start;
}

.prompt-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.prompt-card.is-pending .category-badge {
    background: rgba(251, 191, 36, 0.22);
    color: #facc15;
}

.prompt-card.is-draft .category-badge {
    background: rgba(148, 163, 184, 0.22);
    color: rgba(226, 232, 240, 0.9);
}

.prompt-card .category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.16);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.category-badge a {
    color: inherit;
}


.prompt-card h3 {
    margin: 0 0 1rem;
    font-size: 1.26rem;
    line-height: 1.3;
    background: linear-gradient(90deg, rgba(12, 18, 26, 0.78), rgba(16, 23, 33, 0.92));
    padding: 0.85rem 1.35rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.prompt-card h3 a {
    color: inherit;
    display: block;
}

.prompt-card p {
    margin: 0;
    color: var(--color-muted);
    font-size: 0.95rem;
}

.vote-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    min-width: 3.5rem;
}

.vote-form {
    margin: 0;
}

.vote-button {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(10, 15, 21, 0.65);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vote-button:hover {
    color: #fff;
    border-color: rgba(92, 124, 250, 0.45);
    box-shadow: 0 12px 24px rgba(92, 124, 250, 0.25);
}

.vote-button.is-active {
    background: linear-gradient(135deg, var(--color-primary), #8b5cf6);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow: 0 14px 32px rgba(92, 124, 250, 0.35);
}

.vote-score {
    font-weight: 700;
    font-size: 1.05rem;
    color: #fff;
}

.status-banner {
    margin: 1rem 0 2rem;
    padding: 1rem 1.2rem;
    border-radius: var(--radius-sm);
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.35);
    color: #facc15;
    font-weight: 600;
}

.meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
    color: rgba(243, 245, 249, 0.80); /* Lightened from 0.55 for better readability */
    font-size: 0.85rem; /* Increased from 0.82rem for better readability */
}

.meta-line strong {
    color: rgba(243, 245, 249, 0.95); /* Make version labels more prominent */
    font-weight: 600;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.tag {
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.14);
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.8rem;
    letter-spacing: 0.02em;
}

.sidebar-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 1.6rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-soft);
}

.two-column {
    display: grid;
    gap: 2rem;
}

.two-column-main {
    display: grid;
    gap: 1.5rem;
}

.prompt-detail {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2.2rem;
    box-shadow: var(--shadow-card);
}

.prompt-header {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.6rem;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.prompt-header-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.prompt-detail pre {
    background: rgba(18, 27, 37, 0.92);
    border-radius: var(--radius-md);
    padding: 1.35rem 1.6rem;
    overflow-x: auto;
    white-space: pre-wrap;
    font-family: 'Fira Code', 'Source Code Pro', monospace;
    font-size: 0.95rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
}

.prompt-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2rem;
    font-size: 0.85rem;
    color: var(--color-muted);
    margin-bottom: 1.5rem;
}

.version-list {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.version-pill {
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: rgba(92, 124, 250, 0.18);
    font-weight: 600;
    font-size: 0.8rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.version-pill.is-active {
    background: linear-gradient(135deg, var(--color-primary), #8b5cf6);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 12px 28px rgba(92, 124, 250, 0.35);
}

.version-block {
    display: block;
}

.version-block:not(.is-active) {
    display: none;
}

.comment-list {
    display: grid;
    gap: 1rem;
    margin: 2rem 0 0;
}

.comment {
    background: rgba(12, 17, 23, 0.9);
    border-radius: var(--radius-md);
    padding: 1rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    color: var(--color-muted);
    font-size: 0.82rem;
    margin-bottom: 0.6rem;
}

.form-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 2.2rem;
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(255, 255, 255, 0.09);
}

.form-link {
    display: inline-block;
    margin-top: 0.5rem;
    color: var(--color-primary);
    font-weight: 600;
}

.form-link:hover {
    color: var(--color-accent);
}

.form-grid {
    display: grid;
    gap: 1.2rem;
}

.form-grid label {
    font-weight: 600;
    display: block;
    margin-bottom: 0.4rem;
}

.form-grid input,
.form-grid textarea,
.form-grid select {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(20, 29, 39, 0.94);
    color: var(--color-text);
    font-size: 0.95rem;
}

.form-grid textarea {
    min-height: 160px;
    resize: vertical;
}

.input-hint {
    font-size: 0.78rem;
    color: var(--color-muted);
    margin-top: 0.3rem;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

.inline-form {
    display: inline-flex;
}

.moderation .prompt-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.moderation .form-actions {
    justify-content: flex-start;
}

.prompt-review {
    margin-top: 0.8rem;
}

.prompt-review summary {
    cursor: pointer;
    color: var(--color-primary);
    font-weight: 600;
}

.prompt-review pre {
    margin-top: 0.6rem;
    background: rgba(10, 15, 21, 0.85);
    border-radius: var(--radius-sm);
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    max-height: 260px;
    overflow: auto;
    font-size: 0.9rem;
}

.list-page {
    display: grid;
    gap: 2rem;
}

.filters-bar {
    background: rgba(14, 20, 26, 0.95);
    border-radius: var(--radius-lg);
    padding: 1.3rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: grid;
    gap: 1rem;
}

.filters {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.filters-submit {
    padding: 0.75rem 1.1rem;
    border-radius: var(--radius-sm);
    border: none;
    background: linear-gradient(135deg, var(--color-primary), #7c3aed);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.filters-submit:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-soft);
}


.filters select {
    background: rgba(10, 15, 21, 0.9);
    color: var(--color-text);
}

.filters input[type="search"] {
    background: rgba(10, 15, 21, 0.9);
    color: var(--color-text);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 0.7rem 0.85rem;
    font-size: 0.95rem;
    width: 100%;
}

.filters input[type="search"]::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

.filters input[type="search"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    margin-top: 1.5rem;
}

.pagination a {
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.leaderboard {
    display: grid;
    gap: 2rem;
}

.leaderboard-card {
    background: rgba(14, 20, 26, 0.92);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow-soft);
}

.leaderboard-card h2 {
    margin-top: 0;
    margin-bottom: 1.2rem;
    font-size: 1.3rem;
}

.leaderboard-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.leaderboard-list li {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    align-items: center;
    gap: 1rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.leaderboard-list li:last-child {
    border-bottom: none;
}

.leaderboard-list .rank {
    font-weight: 700;
    color: rgba(92, 124, 250, 0.85);
}

.leaderboard-list .score {
    font-weight: 600;
    color: rgba(110, 231, 183, 0.9);
}

.leaderboard-item .title {
    font-weight: 600;
}

.leaderboard-item .meta {
    display: block;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.leaderboard-item {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: var(--space-xs);
}

.leaderboard-item .title {
    grid-column: 1 / 3;
}

.leaderboard-item .meta {
    grid-column: 1 / 2;
}

.leaderboard-item .premium-pill {
    grid-column: 2 / 3;
    justify-self: end;
    margin: 0;
}

.category-block {
    margin-bottom: 1.4rem;
}

.category-block h3 {
    margin: 1rem 0 0.6rem;
    font-size: 1rem;
    color: rgba(243, 245, 249, 0.9);
}

.category-block ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-block li {
    display: flex;
    justify-content: space-between;
    padding: 0.4rem 0;
    color: rgba(243, 245, 249, 0.85);
}

.category-block li .score {
    color: rgba(110, 231, 183, 0.85);
}


.category-header {
    margin-bottom: 2rem;
}

.category-header h1 {
    margin: 0;
    font-size: 2.1rem;
}
.category-leaderboards {
    display: grid;
    gap: 2rem;
}

.category-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-soft);
}

.category-card.is-premium {
    border-color: rgba(250, 204, 21, 0.3);
    background: linear-gradient(150deg, rgba(250, 204, 21, 0.12), var(--color-card));
}

.category-card h2 {
    margin-top: 0;
    margin-bottom: 0.5rem;
}

.category-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.category-grid ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-grid li {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.4rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    align-items: center;
}

.category-grid li:last-child {
    border-bottom: none;
}

.category-grid .title {
    font-weight: 600;
}

.category-grid .meta {
    grid-column: 1 / -1;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.category-grid .score {
    color: rgba(110, 231, 183, 0.9);
    font-weight: 600;
}

.profile-portfolio {
    display: grid;
    gap: 2rem;
}

.portfolio-header h1 {
    margin: 0;
    font-size: 2rem;
}

.portfolio-header p {
    margin: 0.5rem 0 0;
    color: var(--color-muted);
}

.site-footer {
    margin-top: auto;
    background: rgba(18, 27, 36, 0.88);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: space-between;
    padding: 2.5rem 0;
    color: var(--color-muted);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.75);
}

.footer-meta {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1rem 0;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

.membership-hero {
    margin: 3rem 0;
    padding: 2.8rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(150deg, rgba(92, 124, 250, 0.26), rgba(24, 35, 46, 0.95));
    border: 1px solid rgba(92, 124, 250, 0.38);
    box-shadow: var(--shadow-card);
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.membership-hero h1 {
    font-size: 2.25rem;
    margin-bottom: 1rem;
}

.membership-hero p {
    font-size: 1.05rem;
    color: rgba(243, 245, 249, 0.8);
    max-width: 720px;
}

.membership-benefits {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.membership-benefits .benefit {
    background: rgba(26, 36, 47, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-soft);
}

.membership-benefits h3 {
    margin-top: 0;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.membership-plans {
    margin: 3rem 0;
    text-align: center;
}

.membership-plans h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    align-items: stretch;
}

.pricing-card {
    background: linear-gradient(140deg, rgba(24, 35, 46, 0.96), rgba(92, 124, 250, 0.12));
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-lg);
    padding: 2.2rem 1.9rem;
    text-align: left;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.pricing-card .price {
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    color: #fff;
}

.pricing-card .currency {
    font-size: 1rem;
    color: rgba(243, 245, 249, 0.75);
}

.pricing-card .term {
    font-size: 0.85rem;
    font-weight: 500;
    color: rgba(243, 245, 249, 0.65);
}

.pricing-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    color: rgba(243, 245, 249, 0.8);
}

.pricing-card ul li::before {
    content: '•';
    margin-right: 0.5rem;
    color: rgba(92, 124, 250, 0.6);
}

.membership-plans .btn {
    align-self: flex-start;
}

.membership-plans .membership-note {
    text-align: center;
    margin-top: 2rem;
}

.membership-faq {
    margin: 3rem 0;
}

.membership-faq h2 {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}

.faq-grid h3 {
    margin-top: 0;
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    /* Mobile menu styles are defined earlier in the file - don't override them here */

    .header-search {
        width: 100%;
        margin-left: 0;
    }

    .hero {
        padding: 2.5rem;
    }

    .form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .prompt-card-main,
    .prompt-header {
        grid-template-columns: 1fr;
    }

    .vote-stack {
        flex-direction: row;
        justify-content: flex-start;
        min-width: 0;
    }

    .vote-stack .vote-score {
        order: 2;
    }

    .vote-button {
        width: 38px;
        height: 38px;
    }

    .leaderboard-card h2 {
        font-size: 1.1rem;
    }

    .leaderboard-list li {
        grid-template-columns: 24px 1fr auto;
        font-size: 0.85rem;
        gap: 0.4rem;
        padding: 0.6rem 0.5rem;
    }

    .leaderboard-list .rank {
        font-size: 0.8rem;
    }

    .leaderboard-list .score {
        justify-self: end;
        font-size: 0.8rem;
        white-space: nowrap;
    }

    .leaderboard-list .name {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .leaderboard-item .title {
        font-size: 0.85rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .leaderboard-item .meta {
        font-size: 0.7rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .membership-hero {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        padding: 2.2rem;
    }

    .membership-hero .hero-actions {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

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

@media (prefers-color-scheme: light) {
    :root {
        --color-bg: #f7f9fb;
        --color-text: #0f172a;
        --color-muted: #64748b;
        --color-card: #ffffff;
        --color-surface: #ffffff;
        --color-border: rgba(15, 23, 42, 0.08);
        --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.1);
        --shadow-card: 0 20px 60px rgba(15, 23, 42, 0.12);
    }

    body {
        background: radial-gradient(circle at top, rgba(92, 124, 250, 0.12), transparent 55%), #eef2ff;
    }

    .site-header,
    .site-footer {
        background: rgba(255, 255, 255, 0.9);
    }

    .prompt-card,
    .prompt-detail,
    .form-card,
    .sidebar-card {
        border-color: rgba(15, 23, 42, 0.08);
    }

    .prompt-card:hover {
        border-color: rgba(92, 124, 250, 0.6);
    }

    .vote-button {
        background: rgba(15, 23, 42, 0.05);
        color: var(--color-muted);
        border-color: rgba(15, 23, 42, 0.12);
    }

    .vote-button.is-active {
        color: #fff;
    }

    .vote-score {
        color: var(--color-text);
    }

    .prompt-card.is-pending .category-badge {
        background: rgba(251, 191, 36, 0.18);
        color: #b45309;
    }

    .prompt-card.is-draft .category-badge {
        background: rgba(148, 163, 184, 0.18);
        color: #475569;
    }

    .status-banner {
        background: rgba(251, 191, 36, 0.15);
        border-color: rgba(217, 119, 6, 0.4);
        color: #b45309;
    }
}
