/* Expert Space - CSS
 * Version: v20250209b
 * Unified coach portal styles with brand inheritance
 */

/* ============================================
   CSS VARIABLES (Brand Inheritance)
   ============================================ */
:root {
    /* Brand colors (can be overridden by coach config) */
    --expert-primary: #8B5CF6;
    --expert-primary-hover: #7C3AED;
    --expert-primary-light: #A78BFA;
    --expert-secondary: #6D28D9;

    /* Backgrounds */
    --expert-bg: #FFFFFF;
    --expert-bg-secondary: #F9FAFB;
    --expert-bg-tertiary: #F3F4F6;
    --expert-surface: #FFFFFF;
    --expert-surface-elevated: #FFFFFF;

    /* Text */
    --expert-text: #111827;
    --expert-text-secondary: #4B5563;
    --expert-text-muted: #6B7280;
    --expert-text-light: #9CA3AF;

    /* Borders */
    --expert-border: #E5E7EB;
    --expert-border-light: #F3F4F6;

    /* Status */
    --expert-success: #10B981;
    --expert-success-light: #D1FAE5;
    --expert-warning: #F59E0B;
    --expert-warning-light: #FEF3C7;
    --expert-error: #EF4444;
    --expert-error-light: #FEE2E2;

    /* Typography */
    --expert-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --expert-font-size-xs: 12px;
    --expert-font-size-sm: 14px;
    --expert-font-size-base: 16px;
    --expert-font-size-lg: 18px;
    --expert-font-size-xl: 20px;
    --expert-font-size-2xl: 24px;
    --expert-font-size-3xl: 30px;
    --expert-font-size-4xl: 36px;

    /* Spacing */
    --expert-header-height: 64px;
    --expert-mobile-nav-height: 64px;
    --expert-sidebar-width: 240px;

    /* Radius */
    --expert-radius: 8px;
    --expert-radius-lg: 12px;
    --expert-radius-xl: 16px;
    --expert-radius-2xl: 24px;
    --expert-radius-full: 9999px;

    /* Shadows */
    --expert-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --expert-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
    --expert-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --expert-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Safe areas for mobile */
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    :root.auto-dark {
        --expert-bg: #111827;
        --expert-bg-secondary: #1F2937;
        --expert-bg-tertiary: #374151;
        --expert-surface: #1F2937;
        --expert-surface-elevated: #374151;
        --expert-text: #F9FAFB;
        --expert-text-secondary: #D1D5DB;
        --expert-text-muted: #9CA3AF;
        --expert-text-light: #6B7280;
        --expert-border: #374151;
        --expert-border-light: #1F2937;
    }
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: var(--expert-font);
    font-size: var(--expert-font-size-base);
    line-height: 1.5;
    background: var(--expert-bg);
    color: var(--expert-text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--expert-primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

button {
    font-family: inherit;
    cursor: pointer;
}

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

/* ============================================
   LAYOUT
   ============================================ */
#expert-app {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 100vh;
    overflow: hidden;
}

.expert-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

/* ============================================
   SIDEBAR (Logged-in member nav)
   ============================================ */
.expert-account-sidebar {
    width: var(--expert-sidebar-width);
    position: fixed;
    top: var(--expert-header-height);
    left: 0;
    height: calc(100vh - var(--expert-header-height));
    background: var(--expert-bg);
    border-right: 1px solid var(--expert-border);
    display: flex;
    flex-direction: column;
    z-index: 50;
    overflow-y: auto;
    transition: transform 0.3s ease;
}

.expert-account-sidebar.hidden {
    display: none;
}

#expert-app.has-sidebar .expert-content {
    margin-left: var(--expert-sidebar-width);
}

.sidebar-nav {
    padding: 16px 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--expert-radius);
    color: var(--expert-text-secondary);
    font-family: var(--expert-font);
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    transition: all 0.15s ease;
}

.sidebar-nav-link:hover {
    background: var(--expert-bg-secondary);
    color: var(--expert-text);
}

.sidebar-nav-link.active {
    background: rgba(139, 92, 246, 0.08);
    color: var(--expert-primary);
}

.sidebar-nav-link svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.sidebar-divider {
    height: 1px;
    background: var(--expert-border);
    margin: 8px 12px;
}

.sidebar-footer {
    padding: 12px;
    border-top: 1px solid var(--expert-border);
}

.sidebar-nav-link.danger {
    color: var(--expert-error);
}

.sidebar-nav-link.danger:hover {
    background: var(--expert-error-light);
    color: var(--expert-error);
}

/* Sidebar overlay (mobile) */
.expert-sidebar-overlay {
    display: none;
}

.expert-sidebar-overlay.open {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 49;
}

@media (max-width: 768px) {
    .expert-account-sidebar:not(.hidden) {
        transform: translateX(-100%);
        z-index: 201;
    }

    .expert-account-sidebar:not(.hidden).open {
        transform: translateX(0);
    }

    #expert-app.has-sidebar .expert-content {
        margin-left: 0;
    }
}

/* ============================================
   HEADER
   ============================================ */
.expert-header {
    height: var(--expert-header-height);
    min-height: var(--expert-header-height);
    display: flex;
    align-items: center;
    padding: 0 24px;
    background: var(--expert-bg);
    border-bottom: 1px solid var(--expert-border);
    position: sticky;
    top: 0;
    z-index: 100;
    gap: 16px;
}

.header-left {
    flex-shrink: 0;
}

.header-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
}

.header-profile:hover {
    text-decoration: none;
}

.header-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
}

.header-info {
    display: flex;
    flex-direction: column;
}

.header-name {
    font-size: var(--expert-font-size-base);
    font-weight: 600;
    color: var(--expert-text);
    line-height: 1.2;
}

.header-title {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    line-height: 1.2;
}

/* Navigation */
.header-nav {
    flex: 1;
    display: flex;
    justify-content: center;
    gap: 4px;
}

.nav-tab {
    padding: 8px 16px;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-text-muted);
    text-decoration: none;
    border-radius: var(--expert-radius);
    transition: all 0.15s ease;
    white-space: nowrap;
}

.nav-tab:hover {
    color: var(--expert-text);
    background: var(--expert-bg-secondary);
    text-decoration: none;
}

.nav-tab.active {
    color: var(--expert-primary);
    background: rgba(139, 92, 246, 0.1);
}

/* Header Right */
.header-right {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Mobile hamburger button */
.header-hamburger {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--expert-text-secondary);
    cursor: pointer;
    border-radius: var(--expert-radius);
    transition: all 0.2s;
}

.header-hamburger:hover {
    background: var(--expert-bg-secondary);
    color: var(--expert-text);
}

.header-hamburger svg {
    width: 24px;
    height: 24px;
}

@media (max-width: 768px) {
    .header-hamburger {
        display: flex;
    }

    /* Hide login button on mobile - it's in the hamburger menu */
    .header-right .btn-login,
    .header-right .user-menu {
        display: none;
    }
}

/* ============================================
   TALK BUTTON (Header)
   ============================================ */
.talk-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
    color: white;
    font-size: var(--expert-font-size-sm);
    font-weight: 600;
    border: none;
    border-radius: var(--expert-radius-full);
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

.talk-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.talk-btn svg {
    width: 18px;
    height: 18px;
}

@media (max-width: 768px) {
    .talk-btn {
        display: none;
    }
}

/* ============================================
   TALK DRAWER
   ============================================ */
.talk-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.talk-drawer-overlay.open {
    opacity: 1;
    visibility: visible;
}

.talk-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: 90%;
    max-width: 1200px;
    min-width: 320px;
    height: 100vh;
    background: var(--expert-bg);
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.talk-drawer.open {
    transform: translateX(0);
}

@media (max-width: 768px) {
    .talk-drawer {
        width: 100%;
        max-width: none;
    }
}

.talk-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--expert-border);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), rgba(139, 92, 246, 0.02));
}

.talk-drawer-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.talk-drawer-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
}

.talk-drawer-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--expert-text);
    margin: 0;
}

.talk-drawer-subtitle {
    font-size: 13px;
    color: var(--expert-text-muted);
    margin: 0;
}

.talk-drawer-close {
    width: 36px;
    height: 36px;
    border-radius: var(--expert-radius);
    background: rgba(139, 92, 246, 0.1);
    border: none;
    color: var(--expert-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s;
}

.talk-drawer-close:hover {
    background: rgba(139, 92, 246, 0.2);
}

/* Messages area */
.talk-drawer-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.talk-drawer-welcome {
    text-align: center;
    padding: 40px 20px;
    color: var(--expert-text-secondary);
}

.talk-drawer-welcome p {
    margin: 0 0 12px 0;
    font-size: var(--expert-font-size-base);
    line-height: 1.6;
}

.talk-drawer-welcome-hint {
    color: var(--expert-text-muted);
    font-size: var(--expert-font-size-sm);
}

/* Message bubbles */
.talk-drawer-msg {
    display: flex;
    gap: 12px;
    max-width: 90%;
}

.talk-drawer-msg.user {
    flex-direction: row-reverse;
    margin-left: auto;
}

.talk-drawer-msg-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 14px;
    font-weight: 600;
    overflow: hidden;
}

.talk-drawer-msg-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.talk-drawer-msg-avatar.user {
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
    color: white;
}

.talk-drawer-msg-content {
    background: var(--expert-bg-secondary);
    padding: 12px 16px;
    border-radius: var(--expert-radius-lg);
    border-bottom-left-radius: 4px;
}

.talk-drawer-msg.user .talk-drawer-msg-content {
    background: var(--expert-primary);
    color: white;
    border-radius: var(--expert-radius-lg);
    border-bottom-right-radius: 4px;
}

.talk-drawer-msg-content p {
    margin: 0;
    font-size: var(--expert-font-size-sm);
    line-height: 1.6;
}

/* Typing indicator */
.talk-drawer-typing {
    display: flex;
    gap: 4px;
    padding: 4px 0;
}

.talk-drawer-typing span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--expert-text-muted);
    animation: talkTyping 1.4s infinite ease-in-out both;
}

.talk-drawer-typing span:nth-child(1) { animation-delay: -0.32s; }
.talk-drawer-typing span:nth-child(2) { animation-delay: -0.16s; }

@keyframes talkTyping {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Sticky Quick Access Pills Bar */
.talk-drawer-pills {
    display: flex;
    gap: 8px;
    padding: 12px 20px;
    background: var(--expert-bg-secondary);
    border-bottom: 1px solid var(--expert-border);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-shrink: 0;
}

.talk-drawer-pills::-webkit-scrollbar {
    display: none;
}

.talk-drawer-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: 20px;
    color: var(--expert-text-secondary);
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    font-family: var(--expert-font);
}

.talk-drawer-pill:hover {
    background: var(--expert-bg-tertiary);
    border-color: var(--expert-primary);
    color: var(--expert-text);
}

.talk-drawer-pill.active {
    background: var(--expert-primary);
    border-color: var(--expert-primary);
    color: white;
}

.talk-drawer-pill:active {
    transform: scale(0.96);
}

.talk-drawer-pill svg {
    flex-shrink: 0;
}

/* Suggestion Pills */
.talk-drawer-suggestions {
    padding: 12px 20px 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.talk-drawer-suggestions-loading {
    font-size: 13px;
    color: var(--expert-text-muted);
    padding: 8px 0;
}

.talk-drawer-suggestions-label {
    width: 100%;
    font-size: 12px;
    font-weight: 500;
    color: var(--expert-text-muted);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.talk-drawer-suggestions-label svg {
    width: 14px;
    height: 14px;
    color: var(--expert-primary);
}

.talk-drawer-suggestion {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), rgba(139, 92, 246, 0.03));
    border: 1px solid rgba(139, 92, 246, 0.25);
    border-radius: var(--expert-radius-full);
    font-size: 13px;
    font-weight: 500;
    color: var(--expert-text);
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--expert-font);
}

.talk-drawer-suggestion::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--expert-primary);
    border-radius: 50%;
    flex-shrink: 0;
}

.talk-drawer-suggestion:hover {
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
    color: white;
    border-color: var(--expert-primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.25);
}

.talk-drawer-suggestion:hover::before {
    background: white;
}

.talk-drawer-suggestion:active {
    transform: translateY(0);
}

/* Input area */
.talk-drawer-input-area {
    padding: 16px 20px;
    border-top: 1px solid var(--expert-border);
    background: var(--expert-bg);
}

.talk-drawer-input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 8px 12px;
}

.talk-drawer-input {
    flex: 1;
    border: none;
    background: transparent;
    font-family: var(--expert-font);
    font-size: var(--expert-font-size-base);
    color: var(--expert-text);
    resize: none;
    outline: none;
    min-height: 24px;
    max-height: 120px;
}

.talk-drawer-input::placeholder {
    color: var(--expert-text-muted);
}

.talk-drawer-send {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--expert-primary);
    color: white;
    border: none;
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s;
    flex-shrink: 0;
}

.talk-drawer-send:hover {
    background: var(--expert-primary-hover);
}

.talk-drawer-send svg {
    width: 18px;
    height: 18px;
}

/* Mobile nav Talk highlight */
.mobile-nav-item.talk-highlight {
    color: var(--expert-primary);
}

.mobile-nav-item.talk-highlight svg {
    stroke: var(--expert-primary);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    border-radius: var(--expert-radius);
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn:hover {
    text-decoration: none;
}

.btn-primary {
    background: var(--expert-primary);
    color: white;
}

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

.btn-secondary {
    background: var(--expert-bg-secondary);
    color: var(--expert-text);
    border: 1px solid var(--expert-border);
}

.btn-secondary:hover {
    background: var(--expert-bg-tertiary);
}

.btn-outline {
    background: transparent;
    color: var(--expert-primary);
    border: 1px solid var(--expert-primary);
}

.btn-outline:hover {
    background: rgba(139, 92, 246, 0.1);
}

.btn-ghost {
    background: transparent;
    color: var(--expert-text-muted);
}

.btn-ghost:hover {
    color: var(--expert-text);
    background: var(--expert-bg-secondary);
}

.btn-lg {
    padding: 14px 28px;
    font-size: var(--expert-font-size-base);
}

.btn-sm {
    padding: 6px 12px;
    font-size: var(--expert-font-size-xs);
}

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--expert-radius);
}

/* Login button */
.btn-login {
    padding: 8px 16px;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-primary);
    background: transparent;
    border: 1px solid var(--expert-primary);
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-login:hover {
    background: var(--expert-primary);
    color: white;
}

/* ============================================
   USER MENU
   ============================================ */
.user-menu {
    position: relative;
}

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px 6px 6px;
    background: transparent;
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-full);
    cursor: pointer;
    transition: all 0.15s ease;
}

.user-menu-trigger:hover {
    background: var(--expert-bg-secondary);
    border-color: var(--expert-border);
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--expert-bg-tertiary);
}

.user-name {
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-text);
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tier-badge {
    font-size: var(--expert-font-size-xs);
    padding: 2px 8px;
    background: var(--expert-primary);
    color: white;
    border-radius: var(--expert-radius-full);
    font-weight: 500;
}

.tier-badge.free {
    background: var(--expert-text-muted);
}

.chevron {
    width: 16px;
    height: 16px;
    color: var(--expert-text-muted);
    transition: transform 0.15s ease;
}

.user-menu.open .chevron {
    transform: rotate(180deg);
}

/* Dropdown */
.user-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 220px;
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    box-shadow: var(--expert-shadow-lg);
    z-index: 200;
    overflow: hidden;
}

.dropdown-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--expert-border);
}

.dropdown-header-name {
    font-size: var(--expert-font-size-sm);
    font-weight: 600;
    color: var(--expert-text);
}

.dropdown-header-email {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-text-muted);
    margin-top: 2px;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text);
    text-decoration: none;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: background 0.1s ease;
}

.dropdown-item:hover {
    background: var(--expert-bg-secondary);
    text-decoration: none;
}

.dropdown-item svg {
    width: 18px;
    height: 18px;
    color: var(--expert-text-muted);
}

.dropdown-divider {
    height: 1px;
    background: var(--expert-border);
    margin: 4px 0;
}

.dropdown-item.danger {
    color: var(--expert-error);
}

.dropdown-item.danger svg {
    color: var(--expert-error);
}

/* ============================================
   MOBILE NAVIGATION
   ============================================ */
.expert-mobile-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--expert-mobile-nav-height) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    background: var(--expert-bg);
    border-top: 1px solid var(--expert-border);
    z-index: 100;
}

.mobile-nav-items {
    display: flex;
    height: var(--expert-mobile-nav-height);
}

.mobile-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px;
    color: var(--expert-text-muted);
    text-decoration: none;
    font-size: 10px;
    font-weight: 500;
    transition: color 0.15s ease;
}

.mobile-nav-item svg {
    width: 24px;
    height: 24px;
}

.mobile-nav-item.active {
    color: var(--expert-primary);
}

.mobile-nav-item:hover {
    color: var(--expert-text);
    text-decoration: none;
}

@media (max-width: 768px) {
    .expert-mobile-nav {
        display: block;
    }

    .expert-mobile-nav:not(.hidden) ~ .expert-content {
        padding-bottom: calc(var(--expert-mobile-nav-height) + var(--safe-bottom));
    }

    .header-nav {
        display: none;
    }

    .header-title {
        display: none;
    }

    .expert-header {
        padding: 0 16px;
    }
}

/* ============================================
   MOBILE MENU PANEL (Hamburger)
   ============================================ */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 200;
}

.mobile-menu-overlay.open {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 320px;
    max-width: 85vw;
    background: var(--expert-bg);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    z-index: 201;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mobile-menu-panel.open {
    transform: translateX(0);
}

/* Logged-out header */
.mobile-menu-header-logged-out {
    position: relative;
    padding: 24px 20px;
    text-align: center;
    border-bottom: 1px solid var(--expert-border);
}

.mobile-menu-header-logged-out .mobile-menu-close {
    position: absolute;
    top: 16px;
    right: 16px;
}

.mobile-menu-auth-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--expert-text);
    margin-bottom: 8px;
}

.mobile-menu-auth-subtitle {
    font-size: 13px;
    color: var(--expert-text-secondary);
    margin-bottom: 20px;
    line-height: 1.5;
}

.mobile-menu-auth-btn {
    display: block;
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: var(--expert-radius-lg);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 10px;
}

.mobile-menu-auth-btn.primary {
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
    color: white;
}

.mobile-menu-auth-btn.primary:hover {
    transform: scale(1.02);
}

.mobile-menu-auth-btn.secondary {
    background: var(--expert-bg-secondary);
    color: var(--expert-text);
}

.mobile-menu-auth-btn.secondary:hover {
    background: var(--expert-bg-tertiary);
}

/* Logged-in header */
.mobile-menu-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--expert-border);
}

.mobile-menu-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 600;
    color: white;
    flex-shrink: 0;
    overflow: hidden;
}

.mobile-menu-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mobile-menu-user-info {
    flex: 1;
    min-width: 0;
}

.mobile-menu-user-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--expert-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-menu-tier-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 500;
    border-radius: var(--expert-radius-full);
    margin-top: 4px;
}

.mobile-menu-tier-badge.free {
    background: var(--expert-bg-tertiary);
    color: var(--expert-text-muted);
}

.mobile-menu-tier-badge.paid {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(139, 92, 246, 0.05));
    color: var(--expert-primary);
}

.mobile-menu-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--expert-text-muted);
    cursor: pointer;
    border-radius: var(--expert-radius);
    transition: all 0.2s;
}

.mobile-menu-close:hover {
    background: var(--expert-bg-secondary);
    color: var(--expert-text);
}

/* Menu content */
.mobile-menu-content {
    flex: 1;
    overflow-y: auto;
    padding: 12px 0;
}

.mobile-menu-section {
    padding: 8px 20px;
}

.mobile-menu-section-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--expert-text-muted);
    margin-bottom: 8px;
}

.mobile-menu-divider {
    height: 1px;
    background: var(--expert-border);
    margin: 8px 20px;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px 0;
    background: none;
    border: none;
    color: var(--expert-text);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    transition: color 0.15s;
}

.mobile-menu-item:hover {
    color: var(--expert-primary);
}

.mobile-menu-item.danger {
    color: var(--expert-error);
}

.mobile-menu-item.danger:hover {
    color: var(--expert-error);
}

.mobile-menu-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--expert-text-muted);
}

.mobile-menu-item:hover .mobile-menu-icon {
    color: var(--expert-primary);
}

.mobile-menu-item.danger .mobile-menu-icon {
    color: var(--expert-error);
}

.mobile-menu-text {
    flex: 1;
}

/* ============================================
   CARDS
   ============================================ */
.card {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 24px;
}

.card-elevated {
    box-shadow: var(--expert-shadow-md);
    border: none;
}

.card-interactive {
    cursor: pointer;
    transition: all 0.2s ease;
}

.card-interactive:hover {
    border-color: var(--expert-primary);
    box-shadow: var(--expert-shadow-md);
    transform: translateY(-2px);
}

/* ============================================
   BADGES
   ============================================ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    font-size: var(--expert-font-size-xs);
    font-weight: 500;
    border-radius: var(--expert-radius-full);
}

.badge-primary {
    background: rgba(139, 92, 246, 0.1);
    color: var(--expert-primary);
}

.badge-success {
    background: var(--expert-success-light);
    color: var(--expert-success);
}

.badge-warning {
    background: var(--expert-warning-light);
    color: var(--expert-warning);
}

.badge-error {
    background: var(--expert-error-light);
    color: var(--expert-error);
}

.badge-muted {
    background: var(--expert-bg-tertiary);
    color: var(--expert-text-muted);
}

/* Content type badges */
.badge-lesson {
    background: rgba(59, 130, 246, 0.1);
    color: #3B82F6;
}

.badge-framework {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.badge-worksheet {
    background: rgba(249, 115, 22, 0.1);
    color: #F97316;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-text);
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    font-size: var(--expert-font-size-base);
    font-family: inherit;
    color: var(--expert-text);
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input:focus {
    border-color: var(--expert-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.form-input::placeholder {
    color: var(--expert-text-light);
}

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

.form-hint {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-text-muted);
    margin-top: 4px;
}

.form-error {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-error);
    margin-top: 4px;
}

/* ============================================
   MODAL
   ============================================ */
.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--expert-bg);
    border-radius: var(--expert-radius-xl);
    padding: 32px;
    width: 100%;
    max-width: 420px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--expert-shadow-lg);
    animation: modalIn 0.2s ease;
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--expert-bg-secondary);
    border: none;
    border-radius: 50%;
    color: var(--expert-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.modal-close:hover {
    background: var(--expert-bg-tertiary);
    color: var(--expert-text);
}

.modal-title {
    font-size: var(--expert-font-size-xl);
    font-weight: 600;
    margin-bottom: 8px;
    text-align: center;
}

.modal-subtitle {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    text-align: center;
    margin-bottom: 24px;
}

/* ============================================
   LOADING & ERROR STATES
   ============================================ */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 64px 24px;
    gap: 16px;
    color: var(--expert-text-muted);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--expert-border);
    border-top-color: var(--expert-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 64px 24px;
    text-align: center;
    gap: 16px;
}

.error-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--expert-error-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.error-title {
    font-size: var(--expert-font-size-lg);
    font-weight: 600;
}

.error-message {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    max-width: 400px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
    gap: 12px;
    color: var(--expert-text-muted);
}

.empty-state svg {
    width: 48px;
    height: 48px;
    color: var(--expert-text-light);
    margin-bottom: 8px;
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: var(--expert-text);
    color: var(--expert-bg);
    border-radius: var(--expert-radius);
    box-shadow: var(--expert-shadow-lg);
    font-size: var(--expert-font-size-sm);
    animation: toastIn 0.3s ease;
}

.toast.success {
    background: var(--expert-success);
    color: white;
}

.toast.error {
    background: var(--expert-error);
    color: white;
}

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

@media (max-width: 768px) {
    .toast-container {
        left: 16px;
        right: 16px;
        bottom: calc(var(--expert-mobile-nav-height) + var(--safe-bottom) + 16px);
    }
}

/* ============================================
   PAGE: HOME (PROFILE)
   ============================================ */
.home-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 48px 24px;
}

.profile-hero {
    text-align: center;
    margin-bottom: 48px;
}

.profile-avatar-wrapper {
    position: relative;
    display: inline-block;
    margin-bottom: 20px;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
    border: 4px solid var(--expert-bg);
    box-shadow: var(--expert-shadow-lg);
}

.profile-online-indicator {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 20px;
    height: 20px;
    background: var(--expert-success);
    border-radius: 50%;
    border: 3px solid var(--expert-bg);
}

.profile-name {
    font-size: var(--expert-font-size-3xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.profile-title {
    font-size: var(--expert-font-size-lg);
    color: var(--expert-text-secondary);
    margin-bottom: 16px;
}

.profile-bio {
    font-size: var(--expert-font-size-base);
    color: var(--expert-text-muted);
    max-width: 500px;
    margin: 0 auto 20px;
    line-height: 1.6;
}

.profile-social {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--expert-bg-secondary);
    color: var(--expert-text-muted);
    transition: all 0.15s ease;
}

.social-link:hover {
    background: var(--expert-primary);
    color: white;
}

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

.profile-ctas {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Feature cards grid */
.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 48px;
}

.feature-card {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 28px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.feature-card:hover {
    border-color: var(--expert-primary);
    box-shadow: var(--expert-shadow-md);
    transform: translateY(-4px);
}

.feature-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    border-radius: var(--expert-radius-lg);
    background: rgba(139, 92, 246, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-icon svg {
    width: 28px;
    height: 28px;
    color: var(--expert-primary);
}

.feature-title {
    font-size: var(--expert-font-size-lg);
    font-weight: 600;
    margin-bottom: 8px;
}

.feature-description {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    line-height: 1.5;
}

/* ============================================
   PAGE: TALK (CHAT)
   ============================================ */
.talk-page {
    display: flex;
    flex-direction: column;
    height: calc(100vh - var(--expert-header-height));
    max-width: 720px;
    margin: 0 auto;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.chat-message {
    display: flex;
    gap: 12px;
    max-width: 85%;
}

.chat-message.user {
    flex-direction: row-reverse;
    margin-left: auto;
}

.chat-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
    object-fit: cover;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
}

.chat-message.user .chat-avatar {
    background: var(--expert-bg-tertiary);
}

.chat-bubble {
    background: var(--expert-bg-secondary);
    padding: 12px 16px;
    border-radius: 18px;
    font-size: var(--expert-font-size-base);
    line-height: 1.5;
}

.chat-message.user .chat-bubble {
    background: var(--expert-primary);
    color: white;
}

.chat-bubble p {
    margin: 0;
}

.chat-bubble p + p {
    margin-top: 8px;
}

/* Typing indicator */
.typing-indicator {
    display: flex;
    gap: 12px;
    max-width: 85%;
}

.typing-dots {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 14px 18px;
    background: var(--expert-bg-secondary);
    border-radius: 18px;
}

.typing-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--expert-text-light);
    animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingBounce {
    0%, 60%, 100% {
        transform: translateY(0);
    }
    30% {
        transform: translateY(-6px);
    }
}

/* Chat input */
.chat-input-container {
    padding: 16px 24px;
    border-top: 1px solid var(--expert-border);
    background: var(--expert-bg);
}

.chat-input-row {
    display: flex;
    gap: 12px;
    align-items: flex-end;
}

.chat-input-wrapper {
    flex: 1;
}

.chat-input {
    width: 100%;
    padding: 14px 18px;
    font-size: var(--expert-font-size-base);
    font-family: inherit;
    color: var(--expert-text);
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: 24px;
    outline: none;
    resize: none;
    max-height: 120px;
    transition: border-color 0.15s ease;
}

.chat-input:focus {
    border-color: var(--expert-primary);
}

.chat-input::placeholder {
    color: var(--expert-text-light);
}

.chat-send-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--expert-primary);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.chat-send-btn:hover {
    background: var(--expert-primary-hover);
    transform: scale(1.05);
}

.chat-send-btn:active {
    transform: scale(0.95);
}

.chat-send-btn svg {
    width: 24px;
    height: 24px;
    color: white;
}

/* Suggested questions */
.suggested-questions {
    padding: 0 24px 16px;
}

.suggested-label {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    margin-bottom: 8px;
}

.suggested-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.suggested-pill {
    padding: 8px 14px;
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text);
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-full);
    cursor: pointer;
    transition: all 0.15s ease;
}

.suggested-pill:hover {
    border-color: var(--expert-primary);
    background: rgba(139, 92, 246, 0.05);
}

/* Welcome state */
.chat-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 48px 24px;
}

.chat-welcome-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    margin-bottom: 20px;
    object-fit: cover;
    background: linear-gradient(135deg, var(--expert-primary), var(--expert-primary-light));
}

.chat-welcome-name {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.chat-welcome-tagline {
    font-size: var(--expert-font-size-base);
    color: var(--expert-text-muted);
    margin-bottom: 32px;
    max-width: 400px;
}

@media (max-width: 768px) {
    .talk-page {
        height: calc(100vh - var(--expert-header-height) - var(--expert-mobile-nav-height) - var(--safe-bottom));
    }

    .chat-messages {
        padding: 16px;
    }

    .chat-input-container {
        padding: 12px 16px;
    }
}

/* ============================================
   PAGE: BOOK
   ============================================ */
.book-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 24px;
}

.book-header {
    text-align: center;
    margin-bottom: 40px;
}

.book-title {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.book-subtitle {
    font-size: var(--expert-font-size-base);
    color: var(--expert-text-muted);
}

.book-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.session-types {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.session-type {
    padding: 20px;
    background: var(--expert-surface);
    border: 2px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    cursor: pointer;
    transition: all 0.15s ease;
}

.session-type:hover {
    border-color: var(--expert-primary-light);
}

.session-type.selected {
    border-color: var(--expert-primary);
    background: rgba(139, 92, 246, 0.05);
}

.session-type-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.session-type-name {
    font-size: var(--expert-font-size-base);
    font-weight: 600;
}

.session-type-price {
    font-size: var(--expert-font-size-sm);
    font-weight: 600;
    color: var(--expert-primary);
}

.session-type-duration {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
}

.calendar-container {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 24px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-month {
    font-size: var(--expert-font-size-lg);
    font-weight: 600;
}

.calendar-nav {
    display: flex;
    gap: 8px;
}

.calendar-nav-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    cursor: pointer;
    color: var(--expert-text-muted);
}

.calendar-nav-btn:hover {
    background: var(--expert-bg-tertiary);
    color: var(--expert-text);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.calendar-day-header {
    font-size: var(--expert-font-size-xs);
    font-weight: 500;
    color: var(--expert-text-muted);
    text-align: center;
    padding: 8px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--expert-font-size-sm);
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s ease;
}

.calendar-day:hover:not(.disabled):not(.empty) {
    background: var(--expert-bg-secondary);
}

.calendar-day.selected {
    background: var(--expert-primary);
    color: white;
}

.calendar-day.today {
    font-weight: 600;
    color: var(--expert-primary);
}

.calendar-day.disabled {
    color: var(--expert-text-light);
    cursor: not-allowed;
}

.calendar-day.empty {
    cursor: default;
}

.time-slots {
    margin-top: 24px;
}

.time-slots-label {
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    margin-bottom: 12px;
}

.time-slots-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.time-slot {
    padding: 10px 16px;
    font-size: var(--expert-font-size-sm);
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s ease;
}

.time-slot:hover {
    border-color: var(--expert-primary);
}

.time-slot.selected {
    background: var(--expert-primary);
    border-color: var(--expert-primary);
    color: white;
}

@media (max-width: 768px) {
    .book-layout {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   PAGE: CONTENT
   ============================================ */
.content-page {
    max-width: 1000px;
    margin: 0 auto;
    padding: 32px 24px;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.content-title {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
}

.content-filters {
    display: flex;
    gap: 8px;
}

.filter-btn {
    padding: 8px 16px;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-text-muted);
    background: var(--expert-bg-secondary);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-full);
    cursor: pointer;
    transition: all 0.15s ease;
}

.filter-btn:hover {
    color: var(--expert-text);
    background: var(--expert-bg-tertiary);
}

.filter-btn.active {
    color: var(--expert-primary);
    background: rgba(139, 92, 246, 0.1);
    border-color: var(--expert-primary);
}

.content-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.content-card {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.content-card:hover {
    border-color: var(--expert-primary);
    box-shadow: var(--expert-shadow-md);
}

.content-card-locked {
    opacity: 0.65;
}

.content-card-locked:hover {
    border-color: var(--expert-border);
    box-shadow: none;
    cursor: default;
}

.content-card-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.content-type-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: var(--expert-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2px;
}

.content-icon-lesson {
    background: rgba(59, 130, 246, 0.1);
    color: #3B82F6;
}

.content-icon-framework {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.content-icon-worksheet {
    background: rgba(249, 115, 22, 0.1);
    color: #F97316;
}

.content-card-body {
    flex: 1;
    min-width: 0;
}

.content-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.content-name {
    font-size: var(--expert-font-size-base);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.content-lock-icon {
    flex-shrink: 0;
    color: var(--expert-text-muted);
}

.content-description {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Content Detail Modal */
.content-detail-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.2s ease;
    padding: 24px;
}

.content-detail-overlay.visible {
    opacity: 1;
}

.content-detail-modal {
    background: var(--expert-surface);
    border-radius: var(--expert-radius-lg);
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    padding: 28px;
    transform: translateY(8px);
    transition: transform 0.2s ease;
}

.content-detail-overlay.visible .content-detail-modal {
    transform: translateY(0);
}

.content-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.content-detail-meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.content-detail-close {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--expert-text-muted);
    border-radius: var(--expert-radius);
    transition: color 0.15s ease;
}

.content-detail-close:hover {
    color: var(--expert-text);
}

.content-detail-title {
    font-size: var(--expert-font-size-xl);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 16px;
}

.content-detail-body {
    font-size: var(--expert-font-size-base);
    color: var(--expert-text-secondary);
    line-height: 1.6;
}

.content-detail-body p {
    margin-bottom: 12px;
}

.content-detail-text {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--expert-border);
}

.content-detail-link {
    display: inline-block;
    margin-top: 20px;
    color: var(--expert-primary);
    font-weight: 500;
    font-size: var(--expert-font-size-sm);
    text-decoration: none;
}

.content-detail-link:hover {
    text-decoration: underline;
}

/* ============================================
   PAGE: WORKSHOPS
   ============================================ */
.workshops-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 24px;
}

.workshops-header {
    margin-bottom: 24px;
}

.workshops-title {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.workshops-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
}

.workshop-card {
    display: flex;
    gap: 20px;
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.2s ease;
}

.workshop-card:hover {
    border-color: var(--expert-primary-light);
    box-shadow: var(--expert-shadow);
}

.workshop-date {
    flex-shrink: 0;
    width: 70px;
    text-align: center;
    padding: 12px;
    background: var(--expert-bg-secondary);
    border-radius: var(--expert-radius);
}

.workshop-date-month {
    font-size: var(--expert-font-size-xs);
    font-weight: 600;
    color: var(--expert-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.workshop-date-day {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
    line-height: 1.2;
}

.workshop-date-year {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-text-muted);
}

.workshop-content {
    flex: 1;
}

.workshop-name {
    font-size: var(--expert-font-size-lg);
    font-weight: 600;
    margin-bottom: 6px;
}

.workshop-meta {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    margin-bottom: 8px;
}

.workshop-description {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
}

.workshop-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.workshop-tier {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
}

@media (max-width: 640px) {
    .workshop-card {
        flex-direction: column;
    }

    .workshop-date {
        width: auto;
        display: flex;
        gap: 8px;
        align-items: baseline;
    }
}

/* ============================================
   PAGE: PRICING
   ============================================ */
.pricing-page {
    max-width: 1000px;
    margin: 0 auto;
    padding: 48px 24px;
}

.pricing-header {
    text-align: center;
    margin-bottom: 48px;
}

.pricing-title {
    font-size: var(--expert-font-size-3xl);
    font-weight: 700;
    margin-bottom: 12px;
}

.pricing-subtitle {
    font-size: var(--expert-font-size-lg);
    color: var(--expert-text-muted);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.pricing-card {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-xl);
    padding: 32px;
    position: relative;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    border-color: var(--expert-primary-light);
    box-shadow: var(--expert-shadow-md);
}

.pricing-card.recommended {
    border-color: var(--expert-primary);
    box-shadow: 0 0 0 1px var(--expert-primary);
}

.pricing-card.current {
    border-color: var(--expert-success);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 16px;
    font-size: var(--expert-font-size-xs);
    font-weight: 600;
    background: var(--expert-primary);
    color: white;
    border-radius: var(--expert-radius-full);
}

.pricing-badge.current {
    background: var(--expert-success);
}

.pricing-tier-name {
    font-size: var(--expert-font-size-xl);
    font-weight: 600;
    margin-bottom: 8px;
}

.pricing-tier-price {
    font-size: var(--expert-font-size-4xl);
    font-weight: 700;
    margin-bottom: 4px;
}

.pricing-tier-price span {
    font-size: var(--expert-font-size-base);
    font-weight: 400;
    color: var(--expert-text-muted);
}

.pricing-tier-description {
    font-size: var(--expert-font-size-sm);
    color: var(--expert-text-muted);
    margin-bottom: 24px;
}

.pricing-features {
    list-style: none;
    margin-bottom: 24px;
}

.pricing-feature {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: var(--expert-font-size-sm);
    padding: 8px 0;
}

.pricing-feature svg {
    width: 18px;
    height: 18px;
    color: var(--expert-success);
    flex-shrink: 0;
    margin-top: 2px;
}

.pricing-cta {
    width: 100%;
    margin-top: auto;
}

/* ============================================
   PAGE: ACCOUNT
   ============================================ */
.account-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 24px;
}

.account-header {
    margin-bottom: 24px;
}

.account-title {
    font-size: var(--expert-font-size-2xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.account-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--expert-border);
    margin-bottom: 32px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.account-tab {
    padding: 12px 20px;
    font-size: var(--expert-font-size-sm);
    font-weight: 500;
    color: var(--expert-text-muted);
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.15s ease;
}

.account-tab:hover {
    color: var(--expert-text);
}

.account-tab.active {
    color: var(--expert-primary);
    border-bottom-color: var(--expert-primary);
}

.account-section {
    display: none;
}

.account-section.active {
    display: block;
}

/* Goals */
.goals-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.goal-item {
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    padding: 20px;
}

.goal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.goal-title {
    font-size: var(--expert-font-size-base);
    font-weight: 600;
}

.goal-meta {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-text-muted);
    margin-top: 4px;
}

.goal-progress {
    height: 8px;
    background: var(--expert-bg-secondary);
    border-radius: var(--expert-radius-full);
    overflow: hidden;
}

.goal-progress-bar {
    height: 100%;
    background: var(--expert-primary);
    border-radius: var(--expert-radius-full);
    transition: width 0.3s ease;
}

/* Action Items */
.action-items-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.action-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
}

.action-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--expert-border);
    border-radius: 4px;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.action-checkbox:hover {
    border-color: var(--expert-primary);
}

.action-checkbox.checked {
    background: var(--expert-success);
    border-color: var(--expert-success);
}

.action-checkbox.checked svg {
    color: white;
}

.action-content {
    flex: 1;
}

.action-text {
    font-size: var(--expert-font-size-sm);
}

.action-text.completed {
    text-decoration: line-through;
    color: var(--expert-text-muted);
}

.action-meta {
    font-size: var(--expert-font-size-xs);
    color: var(--expert-text-muted);
    margin-top: 4px;
}

/* Conversations */
.conversations-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.conversation-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--expert-surface);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius-lg);
    cursor: pointer;
    transition: all 0.15s ease;
}

.conversation-card:hover {
    border-color: var(--expert-primary-light);
    box-shadow: var(--expert-shadow-sm);
}

.conversation-date {
    width: 44px;
    height: 44px;
    background: var(--expert-bg-tertiary);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.conversation-day {
    font-size: 16px;
    font-weight: 700;
    color: var(--expert-text);
    line-height: 1;
}

.conversation-month {
    font-size: 10px;
    font-weight: 500;
    color: var(--expert-text-muted);
    text-transform: uppercase;
}

.conversation-info {
    flex: 1;
    min-width: 0;
}

.conversation-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--expert-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.conversation-preview {
    font-size: 12px;
    color: var(--expert-text-muted);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.conversation-meta {
    flex-shrink: 0;
}

.conversation-count {
    font-size: 11px;
    color: var(--expert-text-light);
    background: var(--expert-bg-tertiary);
    padding: 2px 8px;
    border-radius: var(--expert-radius-full);
}

/* ============================================
   UTILITIES
   ============================================ */
.hidden {
    display: none !important;
}

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

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

.text-muted {
    color: var(--expert-text-muted);
}

.mt-4 {
    margin-top: 16px;
}

.mb-4 {
    margin-bottom: 16px;
}

.version-badge {
    position: fixed;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    z-index: 9999;
    pointer-events: none;
}

@media (max-width: 768px) {
    .version-badge {
        bottom: calc(var(--expert-mobile-nav-height) + var(--safe-bottom) + 8px);
    }
}

/* ============================================
   Inline Content Panel in Talk Drawer
   ============================================ */

.talk-content-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.talk-content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.talk-content-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--expert-text);
}

.talk-content-back {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: transparent;
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    color: var(--expert-text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.talk-content-back:hover {
    background: var(--expert-bg-tertiary);
    border-color: var(--expert-primary);
    color: var(--expert-primary);
}

.talk-content-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: var(--expert-text-muted);
}

.talk-content-loading .loading-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--expert-border);
    border-top-color: var(--expert-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.talk-content-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--expert-text-secondary);
}

.talk-content-empty-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px;
    background: var(--expert-bg-tertiary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--expert-text-muted);
}

.talk-content-empty-icon svg {
    width: 24px;
    height: 24px;
}

.talk-content-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Content card with color notch */
.talk-content-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s;
    position: relative;
    overflow: hidden;
}

/* Color notch on the left - simple accent instead of image */
.talk-content-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--expert-primary), var(--expert-primary-light, #A78BFA));
}

/* Alternate colors for different types */
.talk-content-card[data-type="lesson"]::before {
    background: linear-gradient(180deg, #10B981, #34D399);
}

.talk-content-card:hover {
    border-color: var(--expert-primary);
    background: var(--expert-bg-tertiary);
    transform: translateX(2px);
}

.talk-content-card-icon {
    width: 36px;
    height: 36px;
    background: var(--expert-bg-tertiary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--expert-primary);
    flex-shrink: 0;
}

.talk-content-card[data-type="lesson"] .talk-content-card-icon {
    color: #10B981;
}

.talk-content-card-info {
    flex: 1;
    min-width: 0;
}

.talk-content-card-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--expert-text);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.talk-content-card-desc {
    font-size: 12px;
    color: var(--expert-text-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.talk-content-ask-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--expert-primary);
    border: none;
    border-radius: 20px;
    color: white;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
    flex-shrink: 0;
}

.talk-content-ask-btn:hover {
    background: var(--expert-primary-dark);
    transform: scale(1.05);
}

.error-text {
    color: #EF4444;
    text-align: center;
    padding: 20px;
}

/* Streaming cursor animation */
.streaming-cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: var(--expert-primary);
    margin-left: 2px;
    animation: blink 0.7s infinite;
    vertical-align: text-bottom;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.streaming-text {
    display: inline;
}

/* Talk Home View */
.talk-home-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
}

.talk-home-profile {
    margin-bottom: 24px;
}

.talk-home-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 16px;
    border: 3px solid var(--expert-primary);
}

.talk-home-name {
    font-size: 22px;
    font-weight: 700;
    color: var(--expert-text);
    margin: 0 0 8px 0;
}

.talk-home-tagline {
    font-size: 14px;
    color: var(--expert-text-secondary);
    margin: 0;
}

.talk-home-bio {
    max-width: 500px;
    margin-bottom: 24px;
}

.talk-home-bio p {
    font-size: 15px;
    line-height: 1.6;
    color: var(--expert-text-secondary);
    margin: 0;
}

.talk-home-cta {
    margin-top: 16px;
}

.talk-home-hint {
    font-size: 13px;
    color: var(--expert-text-muted);
    margin: 0;
}

/* Goals Panel */
.talk-goals-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.talk-goal-card {
    padding: 16px;
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    position: relative;
    overflow: hidden;
}

.talk-goal-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #F59E0B, #FBBF24);
}

.talk-goal-card.completed::before {
    background: linear-gradient(180deg, #10B981, #34D399);
}

.talk-goal-header {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
}

.talk-goal-icon {
    width: 32px;
    height: 32px;
    background: rgba(245, 158, 11, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #F59E0B;
    flex-shrink: 0;
}

.talk-goal-card.completed .talk-goal-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.talk-goal-info {
    flex: 1;
}

.talk-goal-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--expert-text);
}

.talk-goal-due {
    font-size: 12px;
    color: var(--expert-text-muted);
    margin-top: 2px;
}

.talk-goal-desc {
    font-size: 13px;
    color: var(--expert-text-secondary);
    margin-bottom: 12px;
    line-height: 1.4;
}

.talk-goal-progress {
    display: flex;
    align-items: center;
    gap: 10px;
}

.talk-goal-progress-bar {
    flex: 1;
    height: 6px;
    background: var(--expert-bg-tertiary);
    border-radius: 3px;
    overflow: hidden;
}

.talk-goal-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #F59E0B, #FBBF24);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.talk-goal-card.completed .talk-goal-progress-fill {
    background: linear-gradient(90deg, #10B981, #34D399);
}

.talk-goal-progress-text {
    font-size: 12px;
    font-weight: 600;
    color: var(--expert-text-muted);
    min-width: 36px;
    text-align: right;
}

/* History Panel */
.talk-history-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.talk-history-card {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--expert-bg);
    border: 1px solid var(--expert-border);
    border-radius: var(--expert-radius);
    cursor: pointer;
    transition: all 0.15s;
}

.talk-history-card:hover {
    border-color: var(--expert-primary);
    background: var(--expert-bg-tertiary);
}

.talk-history-date {
    width: 44px;
    height: 44px;
    background: var(--expert-bg-tertiary);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.talk-history-day {
    font-size: 16px;
    font-weight: 700;
    color: var(--expert-text);
    line-height: 1;
}

.talk-history-month {
    font-size: 10px;
    font-weight: 500;
    color: var(--expert-text-muted);
    text-transform: uppercase;
}

.talk-history-info {
    flex: 1;
    min-width: 0;
}

.talk-history-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--expert-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.talk-history-preview {
    font-size: 12px;
    color: var(--expert-text-muted);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
