:root {
    /* Premium Color Palette */
    --bg-dark: #000000;
    --bg-surface-1: #0f0f11;
    /* Slightly lighter black */
    --bg-surface-2: #1c1c1e;
    /* Dark gray */

    --text-primary: #ffffff;
    --text-secondary: #86868b;
    --text-tertiary: #6e6e73;

    --accent-primary: #2997ff;
    /* Apple Blue */
    --accent-secondary: #bf5af2;
    /* Purple */
    --accent-glow: rgba(41, 151, 255, 0.5);

    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(28, 28, 30, 0.65);

    --font-main: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;

    --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
}

:root[data-theme="light"] {
    --bg-dark: #f6f7fb;
    --bg-surface-1: #ffffff;
    --bg-surface-2: #eef1f7;
    --text-primary: #0f172a;
    --text-secondary: #334155;
    --text-tertiary: #475569;
    --accent-primary: #2563eb;
    --accent-secondary: #7c3aed;
    --accent-glow: rgba(37, 99, 235, 0.25);
    --glass-border: rgba(15, 23, 42, 0.08);
    --glass-bg: rgba(255, 255, 255, 0.8);
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-main);
    margin: 0;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-top: 0;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    background: linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.7) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

p {
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Utilities */
.text-gradient {
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
}

.glass-panel-premium {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 32px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transition: transform 0.6s var(--ease-out-expo), box-shadow 0.6s var(--ease-out-expo);
}

.glass-panel-premium:hover {
    transform: scale(1.02);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
    border-color: rgba(255, 255, 255, 0.15);
}

.btn-primary {
    background: var(--text-primary);
    color: var(--bg-dark);
    padding: 12px 24px;
    border-radius: 980px;
    /* Pill shape */
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: 980px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s var(--ease-out-expo), transform 1s var(--ease-out-expo);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Lock Section */
.scroll-lock-section {
    display: flex;
    padding: 100px 20px;
    max-width: 1200px;
    margin: 0 auto;
    gap: 60px;
}

.scroll-content {
    flex: 1;
}

.scroll-step {
    min-height: 80vh;
    /* Each step takes up screen height */
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0.3;
    transition: opacity 0.5s;
}

.scroll-step.active {
    opacity: 1;
}

.sticky-visual {
    flex: 1;
    position: sticky;
    top: 100px;
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.visual-item {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
    display: flex;
    align-items: center;
    justify-content: center;
}

.visual-item.active {
    opacity: 1;
    transform: scale(1);
}

/* Bento Grid */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1200px;
    margin: 100px auto;
    padding: 0 20px;
}

.bento-item {
    background: var(--bg-surface-1);
    border-radius: 32px;
    padding: 40px;
    border: 1px solid var(--glass-border);
    overflow: hidden;
    position: relative;
}

.bento-item.large {
    grid-column: span 2;
}

/* Navigation */
.nav-dock {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(28, 28, 30, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 12px 24px;
    border-radius: 980px;
    display: flex;
    gap: 24px;
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .nav-dock {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.15);
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-top: 0;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    background: linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.7) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

p {
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Utilities */
.text-gradient {
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
}

.glass-panel-premium {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 32px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transition: transform 0.6s var(--ease-out-expo), box-shadow 0.6s var(--ease-out-expo);
}

.glass-panel-premium:hover {
    transform: scale(1.02);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
    border-color: rgba(255, 255, 255, 0.15);
}

.btn-primary {
    background: var(--text-primary);
    color: var(--bg-dark);
    padding: 12px 24px;
    border-radius: 980px;
    /* Pill shape */
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.ql-bubble .ql-editor code, .ql-bubble .ql-editor pre {
    background-color: rgba(0, 0, 0, 0.3) !important;
    color: #e5e7eb;
    font-family: 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin: 0 0.2rem;
}

.theme-toggle {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1100;
}

.theme-toggle-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: var(--text-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.theme-toggle-btn:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
    border-color: rgba(255, 255, 255, 0.25);
}

[data-theme="light"] .theme-toggle-btn {
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.2);
    border-color: rgba(15, 23, 42, 0.08);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: 980px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s var(--ease-out-expo), transform 1s var(--ease-out-expo);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Lock Section */
.scroll-lock-section {
    display: flex;
    padding: 100px 20px;
    max-width: 1200px;
    margin: 0 auto;
    gap: 60px;
}

.scroll-content {
    flex: 1;
}

.scroll-step {
    min-height: 80vh;
    /* Each step takes up screen height */
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0.3;
    transition: opacity 0.5s;
}

.scroll-step.active {
    opacity: 1;
}

.sticky-visual {
    flex: 1;
    position: sticky;
    top: 100px;
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.visual-item {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
    display: flex;
    align-items: center;
    justify-content: center;
}

.visual-item.active {
    opacity: 1;
    transform: scale(1);
}

/* Bento Grid */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1200px;
    margin: 100px auto;
    padding: 0 20px;
}

.bento-item {
    background: var(--bg-surface-1);
    border-radius: 32px;
    padding: 40px;
    border: 1px solid var(--glass-border);
    overflow: hidden;
    position: relative;
}

.bento-item.large {
    grid-column: span 2;
}

/* Navigation */
.nav-dock {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(28, 28, 30, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 8px 20px;
    border-radius: 980px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    white-space: nowrap;
    padding: 6px 12px;
    border-radius: 980px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link i {
    margin-right: 6px;
    font-size: 0.85rem;
}

/* Autofill fix for dark mode */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px #1c1c1e inset !important;
    -webkit-text-fill-color: white !important;
}

/* Quick Edit Modal Styles */
.quick-edit-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 3000;
    align-items: center;
    justify-content: center;
}

.quick-edit-modal.open {
    display: flex;
}

.quick-edit-content {
    background: var(--bg-surface-1);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.5rem;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.quick-edit-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 32px;
    border-bottom: 1px solid var(--glass-border);
    background: var(--bg-surface-1);
}

.quick-edit-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Preference Toggle Styles */
.pref-toggle {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.pref-toggle input[type="checkbox"] {
    display: none;
}


.pref-toggle:hover .pref-card {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.pref-toggle input:checked + .pref-card,
.pref-toggle .pref-card.active {
    background: rgba(34, 197, 94, 0.15);
    border-color: rgb(34, 197, 94);
    color: white;
}

.pref-toggle input:checked + .pref-card i,
.pref-toggle .pref-card.active i {
    color: rgb(34, 197, 94);
}

.pref-toggle input:checked + .pref-card span:last-child,
.pref-toggle .pref-card.active span:last-child {
    color: rgba(255, 255, 255, 0.7);
}

/* Preference Option Styles */
.pref-option {
    cursor: pointer;
    user-select: none;
}

.pref-option input[type="radio"] {
    display: none;
}

.pref-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    border-radius: 16px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
    text-align: center;
}

.pref-card.active {
    border-color: var(--accent-primary);
    background: rgba(41, 151, 255, 0.1);
    box-shadow: 0 0 20px rgba(41, 151, 255, 0.2);
}

.pref-card i {
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.pref-card.active i {
    color: var(--accent-primary);
}


/* Quick Edit Button Styles */
.quick-edit-btn {
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.quick-edit-btn-primary {
    background: var(--accent-primary);
    color: white;
}

.quick-edit-btn-primary:hover {
    background: rgba(41, 151, 255, 0.8);
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(41, 151, 255, 0.3);
}

.quick-edit-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.quick-edit-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Line clamp utility */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Custom Scrollbar for Language Dropdown */
.custom-scrollbar::-webkit-scrollbar {
    width: 4px;
}
.custom-scrollbar::-webkit-scrollbar-track {
    background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Hide Google Translate top bar */
body {
    top: 0 !important;
}

.goog-te-banner-frame.skiptranslate, 
.goog-te-banner-frame {
    display: none !important;
}

.goog-tooltip, 
.goog-tooltip:hover {
    display: none !important;
}

.goog-text-highlight {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* Ensure translated content doesn't break layout */
.skiptranslate {
    display: none !important;
}

#google_translate_element {
    display: none !important;
}