/* ============================================
   ORIENTAL FANTASY - Mystical Theme
   Dịch Lý Ứng Dụng (like luangiai.ai)
   ============================================ */

:root {
    /* Solid deep purple (mystical) */
    --bg-deep: #1a0b2e;
    /* Text - white */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.95);
    --text-muted: rgba(255, 255, 255, 0.85);
    --text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    --heading-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    /* Primary buttons - vàng cam (Oriental Fantasy) */
    --button-primary: linear-gradient(to right, #f59e0b, #d97706);
    --button-primary-text: #ffffff;
    --button-primary-text-alt: #422006;
    /* Dark Glass */
    --glass-bg: rgba(15, 23, 42, 0.6);
    --glass-border: 1px solid rgba(255, 255, 255, 0.15);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    --glass-blur: 15px;
    --glass-radius: 20px;
}

* {
    font-family: Arial, sans-serif !important;
}

/* Icon styling - Ensure Font Awesome icons display correctly - MUST come after * selector */
i.fas, i.fab, i.far, i.fal, i.fad, i.fa,
[class*="fa-"], [class^="fa-"] {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Pro", "Font Awesome 6 Brands", "FontAwesome" !important;
    font-weight: 900 !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-transform: none !important;
    line-height: 1 !important;
    display: inline-block !important;
    vertical-align: middle !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
    speak: none !important;
}

i.fab, [class*="fab fa-"] {
    font-family: "Font Awesome 6 Brands", "FontAwesome" !important;
    font-weight: 400 !important;
}

/* Ensure icons align properly in buttons */
button i.fas, button i.fab, button i.fa, button [class*="fa-"],
a i.fas, a i.fab, a i.fa, a [class*="fa-"] {
    vertical-align: middle !important;
    line-height: 1 !important;
}

/* Typography - Arial everywhere, headings stand out on complex background */
h1, h2, h3, .app-title, .app-slogan, body, input, select, textarea, button, label {
    font-family: Arial, sans-serif !important;
}
h1, h2, h3, .app-title {
    text-shadow: var(--heading-shadow);
    color: #ffffff;
}

body {
    /* Solid deep purple - no gradients, no background images */
    background-color: #1a0b2e;
    color: var(--text-primary);
    text-shadow: var(--text-shadow);
    min-height: 100vh;
    margin: 0;
    font-family: Arial, sans-serif !important;
}

/* Dark Glass - Oriental Fantasy */
.glass, #cong-cu-container, .tool-content,
.bg-gray-900\/50, .hexagram-container, .picker-content, .qr-content,
.history-card, .chat-msg, #chat-history, .notification,
.footer-contact {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: var(--glass-radius);
}

/* Theme overrides - vàng trắng */
#cong-cu-container .text-yellow-500,
#cong-cu-container .text-yellow-400 { color: #ffffff !important; text-shadow: var(--text-shadow); }
#cong-cu-container .text-gray-400 { color: var(--text-muted) !important; text-shadow: var(--text-shadow); }
#cong-cu-container .border-gray-700,
#cong-cu-container .border-gray-600,
#cong-cu-container .border-gray-500 { border-color: rgba(255, 255, 255, 0.15) !important; }
#cong-cu-container .bg-gray-900\/50,
#cong-cu-container [class*="bg-gray-900"] {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border) !important;
    box-shadow: var(--glass-shadow);
    border-radius: var(--glass-radius);
}
/* Ô hiển thị Âm lịch - nền đen mờ, viền xám tối, thống nhất với ô nhập */
#cong-cu-container .time-display-box.bg-gray-800 {
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid #4B5563 !important;
    border-radius: 0.5rem;
}
#cong-cu-container .bg-gray-800 {
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid #4B5563 !important;
    border-radius: 0.5rem;
}

#cong-cu-container {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border);
    box-shadow: var(--glass-shadow);
    padding: 2rem;
    border-radius: var(--glass-radius);
    overflow: hidden;
}

/* === MINI HEADER (Quay lại Trang Chủ) === */
.app-mini-header {
    text-align: left;
    margin: -2rem -2rem 0.5rem -2rem;
    padding: 0.5rem 0 0.5rem 2rem;
    background: transparent;
    border-radius: 0;
}
.app-mini-header-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    padding: 0.35rem 0.5rem;
    border-radius: 0.25rem;
    transition: color 0.2s, background 0.2s;
}
.app-mini-header-link:hover {
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.1);
}
.app-mini-header-link i {
    font-size: 0.875rem;
}

/* === HEADER === */
.app-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: none;
    box-shadow: none;
    padding: 1.25rem 2rem 1.75rem;
    margin: -2rem -2rem 2.5rem -2rem;
    border-radius: 0;
}

.app-title {
    font-family: Arial, sans-serif !important;
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    line-height: 1.3;
    text-transform: uppercase;
    color: #ffffff;
    text-shadow: var(--heading-shadow);
    margin: 0;
}

.app-slogan {
    font-family: Arial, sans-serif !important;
    margin: 0.5rem 0 0;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: normal;
    line-height: 1.4;
    color: #ffffff;
    text-shadow: var(--heading-shadow);
}

@media (min-width: 768px) {
    .app-title {
        font-size: 2.25rem;
    }
    .app-slogan {
        font-size: 1.0625rem;
    }
}

/* === BUTTONS - Fire/Light gradient (Oriental Fantasy) === */
#gieoQueBtn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: var(--glass-radius);
    padding: 0.75rem 3rem;
    font-size: 1.125rem;
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    text-transform: uppercase;
    width: auto;
    min-width: 250px;
    display: inline-block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    box-shadow: var(--glass-shadow);
}
#gieoQueBtn:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}

/* Luận Sim App - nút CTA (giống hệt #gieoQueBtn) */
.main-cta-btn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: var(--glass-radius);
    padding: 0.75rem 3rem;
    font-size: 1.125rem;
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    text-transform: uppercase;
    width: auto;
    min-width: 250px;
    display: inline-block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    box-shadow: var(--glass-shadow);
    cursor: pointer;
}
.main-cta-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}
.thailuu-ai-btn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    padding: 0.8rem 2rem;
    border-radius: var(--glass-radius);
    cursor: pointer;
    box-shadow: var(--glass-shadow);
    transition: all 0.3s;
    width: auto;
    font-size: 1.1rem;
}
.thailuu-ai-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}
.thailuu-ai-btn:disabled {
    opacity: 0.8;
    cursor: not-allowed;
    transform: none;
}
.pdf-export-btn {
    background: var(--glass-bg);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.4);
    padding: 0.65rem 1.5rem;
    border-radius: var(--glass-radius);
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--glass-shadow);
}
.pdf-export-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.25);
}
.phone-input {
    width: 100%;
    padding: 14px 88px 14px 16px;
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.5rem;
    color: #fff;
    font-size: 1rem;
}
.sim-timeline-scroll {
    -webkit-overflow-scrolling: touch;
}

.sim-ai-loading {
    text-align: center;
    padding: 1.5rem;
}
.sim-spinner {
    width: 40px;
    height: 40px;
    margin: 0 auto;
    border: 3px solid rgba(245, 158, 11, 0.3);
    border-top-color: #f59e0b;
    border-radius: 50%;
    animation: sim-spin 0.8s linear infinite;
}
@keyframes sim-spin {
    to { transform: rotate(360deg); }
}

/* App Sim - Mini header với nút Lịch sử */
.sim-mini-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 2rem;
}
.sim-mini-header .app-mini-header-link {
    font-size: 1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    background: transparent;
    border: none;
    transition: color 0.2s;
}
.sim-mini-header .app-mini-header-link:hover {
    color: #fbbf24;
}
.sim-mini-header .app-mini-header-link i {
    font-size: 1rem;
}
.sim-history-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    background: transparent;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: color 0.2s;
}
.sim-history-btn:hover {
    color: #fbbf24;
}
.sim-history-btn i {
    font-size: 1rem;
}

/* App Sim - Modal Lịch sử */
.sim-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}
.sim-modal.active {
    opacity: 1;
    pointer-events: auto;
}
.sim-modal-content {
    background: var(--glass-bg);
    border: var(--glass-border);
    border-radius: var(--glass-radius);
    padding: 1.25rem;
    max-width: 400px;
    width: 100%;
    max-height: 70vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--glass-shadow);
}
.sim-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.sim-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.sim-history-clear-btn {
    display: inline-flex;
    align-items: center;
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    padding: 0.35rem 0.6rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}
.sim-history-clear-btn:hover {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.35);
    border-color: rgba(239, 68, 68, 0.6);
}
.sim-modal-close {
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    font-size: 1.25rem;
    padding: 0.25rem;
}
.sim-modal-close:hover {
    color: #f59e0b;
}
.sim-history-modal-list {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.sim-history-modal-item {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    text-align: left;
    color: #fff;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.375rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    font-size: 1rem;
    transition: border-color 0.2s, background 0.2s;
}
.sim-history-modal-item:hover {
    border-color: rgba(245, 158, 11, 0.4);
    background: rgba(245, 158, 11, 0.08);
}
.sim-history-empty {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    padding: 1rem;
    text-align: center;
}

/* App Sim - Biểu đồ năng lượng (Energy Bar Chart) */
.sim-score-block {
    margin-bottom: 1.5rem;
}
.sim-score-block.hidden {
    display: none !important;
}
.sim-energy-chart {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
}
.sim-energy-bar {
    margin-bottom: 0.75rem;
}
.sim-energy-bar:last-of-type {
    margin-bottom: 0;
}
.sim-energy-bar--thuThach {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px dashed rgba(255, 255, 255, 0.2);
}
.sim-energy-bar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}
.sim-energy-bar-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.75);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.sim-energy-bar-level {
    font-size: 0.6875rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
}
.sim-energy-bar-track {
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
}
.sim-energy-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

/* App Sim - Tiêu đề kết quả: phân tích cặp số, icon huyền học hiện đại */
.sim-result-section-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: #fbbf24;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-shadow: 0 0 20px rgba(251, 191, 36, 0.25);
}
.sim-result-section-icon {
    font-size: 1.5rem;
    color: #fbbf24;
    filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.5));
    animation: sim-icon-glow 3s ease-in-out infinite;
}
@keyframes sim-icon-glow {
    0%, 100% { opacity: 1; filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.5)); }
    50% { opacity: 0.9; filter: drop-shadow(0 0 14px rgba(251, 191, 36, 0.7)); }
}

/* App Sim - 5 Nguyên tắc vàng (Accordion Tâm Pháp - Luxury) */
.principles-section {
    width: 100%;
}
.principles-details {
    border-radius: 8px;
    overflow: hidden;
}
.principles-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.875rem 1rem;
    background: linear-gradient(to right, #1f2937, #111827);
    border-top: 1px solid rgba(245, 158, 11, 0.3);
    border-bottom: 1px solid rgba(245, 158, 11, 0.3);
    color: #fcd34d;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    cursor: pointer;
    list-style: none;
    user-select: none;
    transition: background 0.2s ease;
}
.principles-summary::-webkit-details-marker,
.principles-summary::marker {
    display: none;
}
.principles-summary:hover {
    background: linear-gradient(to right, #374151, #1f2937);
}
.principles-summary-text {
    text-align: center;
}
.principles-summary-arrow {
    font-size: 0.75rem;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}
.principles-details[open] .principles-summary-arrow {
    transform: rotate(180deg);
}
.principles-content {
    padding: 1.25rem 1.5rem;
    background: rgba(17, 24, 39, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-top: none;
    border-radius: 0 0 8px 8px;
}
.principles-item {
    margin: 0 0 0.75rem 0;
    padding-left: 0.25rem;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.9375rem;
    line-height: 1.5;
}
.principles-item:last-child {
    margin-bottom: 0;
}
.principles-item strong {
    color: rgba(253, 224, 71, 0.95);
}
.principles-item em {
    color: rgba(226, 232, 240, 0.85);
    font-style: italic;
}
.principles-item-icon {
    color: #fcd34d;
    margin-right: 0.5rem;
    font-size: 0.75rem;
}

/* App Sim - Card Grid: dãn thẻ theo bề rộng trang, tỷ lệ cân đối */
.sim-timeline-wrap {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    gap: 15px;
    padding: 0.5rem 0 1rem;
    width: 100%;
}
.sim-timeline-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    gap: 15px;
    width: 100%;
    max-width: 100%;
}
.sim-timeline-card {
    width: 120px;
    min-height: 200px;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0.75rem 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    box-shadow: none;
    transition: opacity 0.2s ease;
    cursor: pointer;
}
.sim-timeline-card:hover {
    opacity: 0.95;
}
.sim-timeline-card--tienTai .hex-seal-wrapper {
    border-color: #F59E0B;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.5), inset 0 0 10px rgba(245, 158, 11, 0.15);
}
.sim-timeline-card--tienTai .sim-timeline-card-name { color: #F59E0B; text-shadow: 0 0 12px rgba(245, 158, 11, 0.4); }
.sim-timeline-card--triTue .hex-seal-wrapper {
    border-color: #3B82F6;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5), inset 0 0 10px rgba(59, 130, 246, 0.15);
}
.sim-timeline-card--triTue .sim-timeline-card-name { color: #3B82F6; text-shadow: 0 0 12px rgba(59, 130, 246, 0.4); }
.sim-timeline-card--nhanSu .hex-seal-wrapper {
    border-color: #8B5CF6;
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.5), inset 0 0 10px rgba(139, 92, 246, 0.15);
}
.sim-timeline-card--nhanSu .sim-timeline-card-name { color: #8B5CF6; text-shadow: 0 0 12px rgba(139, 92, 246, 0.4); }
.sim-timeline-card--canBang .hex-seal-wrapper {
    border-color: #10B981;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.5), inset 0 0 10px rgba(16, 185, 129, 0.15);
}
.sim-timeline-card--canBang .sim-timeline-card-name { color: #10B981; text-shadow: 0 0 12px rgba(16, 185, 129, 0.4); }
.sim-timeline-card--binh .hex-seal-wrapper {
    border-color: #9CA3AF;
    box-shadow: 0 0 12px rgba(156, 163, 175, 0.3), inset 0 0 10px rgba(0, 0, 0, 0.3);
}
.sim-timeline-card--binh .sim-timeline-card-name { color: #9CA3AF; }
.sim-timeline-card-num {
    font-size: 1.375rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.35rem;
    letter-spacing: 0.04em;
    line-height: 1.2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.sim-timeline-card-canvas {
    margin: 0.2rem 0;
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}
.hex-seal-wrapper {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: #0a0a0a;
    background: radial-gradient(ellipse at center, #1a1a1a 0%, #0a0a0a 70%);
    border: 1px solid #F59E0B;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.3), inset 0 0 10px rgba(245, 158, 11, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
.sim-timeline-card-canvas canvas {
    display: block;
}
.sim-timeline-card.meaning-open {
    min-height: auto;
}
.sim-timeline-card-name {
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: auto;
    line-height: 1.3;
    min-height: 2em;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.sim-timeline-card-icons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    margin-top: 0.35rem;
    flex-wrap: wrap;
}
.sim-card-icon {
    font-size: 1rem;
    line-height: 1;
}
/* Ý nghĩa quẻ dưới mỗi card - bấm expand */
.sim-card-meaning {
    width: 100%;
    margin-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 0.5rem;
}
.sim-card-meaning-header {
    width: 100%;
    padding: 0.4rem 0;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.35rem;
    transition: color 0.2s;
}
.sim-card-meaning-header:hover {
    color: #fbbf24;
}
.sim-card-meaning-header i {
    font-size: 0.65rem;
    transition: transform 0.25s ease;
}
.sim-timeline-card.meaning-open .sim-card-meaning-header i {
    transform: rotate(180deg);
}
.sim-card-meaning-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.sim-timeline-card.meaning-open .sim-card-meaning-body {
    max-height: 280px;
}
.sim-card-meaning-body-inner {
    padding: 0.5rem 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.6875rem;
    line-height: 1.5;
    text-align: left;
    overflow-y: auto;
    max-height: 260px;
}
.sim-timeline-arrow {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.5rem;
    color: rgba(255, 255, 255, 0.22);
    font-size: 1.125rem;
    width: 24px;
}

/* App Sim - Luận giải chi tiết: list mobile / grid 2 cột desktop */
.sim-detail-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}
@media (min-width: 768px) {
    .sim-detail-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
.sim-detail-block {
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--glass-radius);
    background: rgba(0, 0, 0, 0.25);
    padding: 1rem 1.25rem;
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.sim-detail-block.sim-detail-block-active {
    background: rgba(251, 191, 36, 0.12);
    border-color: rgba(251, 191, 36, 0.45);
    box-shadow: 0 0 0 1px rgba(251, 191, 36, 0.2);
}
.sim-detail-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.5rem 0.75rem;
    margin: 0 0 0.5rem 0;
}
.sim-detail-title {
    font-size: 1rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.85);
    font-family: Arial, sans-serif !important;
}
.sim-detail-title--cat {
    color: #fbbf24;
    text-shadow: 0 0 12px rgba(251, 191, 36, 0.35);
}
.sim-detail-tags {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}
.sim-detail-tag {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #f59e0b;
    background: transparent;
    border: 1px solid rgba(245, 158, 11, 0.6);
    border-radius: 0.25rem;
    padding: 0.2rem 0.4rem;
    line-height: 1;
}
.sim-detail-content {
    color: rgba(209, 213, 219, 1);
    font-size: 0.9375rem;
    line-height: 1.75;
    margin: 0;
}

/* App Sim - Luận giải chi tiết: accordion cân xứng, thu hút */
.sim-accordion {
    border: var(--glass-border);
    border-radius: var(--glass-radius);
    overflow: hidden;
    background: var(--glass-bg);
    box-shadow: var(--glass-shadow);
}
.sim-accordion-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.sim-accordion-item:last-child {
    border-bottom: none;
}
.sim-accordion-header {
    width: 100%;
    padding: 1rem 1.25rem;
    text-align: left;
    background: rgba(0, 0, 0, 0.2);
    border: none;
    color: #fbbf24;
    font-weight: 700;
    font-size: 1rem;
    font-family: Arial, sans-serif !important;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    transition: background 0.2s, border-color 0.2s;
    border-left: 3px solid transparent;
}
.sim-accordion-header:hover {
    background: rgba(245, 158, 11, 0.08);
}
.sim-accordion-header span {
    flex: 1;
}
.sim-accordion-header i.fa-chevron-down {
    transition: transform 0.25s ease;
    opacity: 0.9;
    flex-shrink: 0;
    color: #f59e0b;
}
.sim-accordion-item.open .sim-accordion-header {
    background: rgba(245, 158, 11, 0.12);
    border-left-color: #f59e0b;
}
.sim-accordion-item.open .sim-accordion-header i.fa-chevron-down {
    transform: rotate(180deg);
}
.sim-accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}
.sim-accordion-item.open .sim-accordion-body {
    max-height: 520px;
}
.sim-accordion-body-inner {
    padding: 1.25rem 1.25rem 1.5rem;
    background: rgba(17, 24, 39, 0.5);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.9375rem;
    line-height: 1.75;
    text-align: left;
    border-left: 3px solid rgba(245, 158, 11, 0.35);
    margin-left: 0;
}

/* App Sim - Mobile: Card Grid giữ nguyên, chỉ điều chỉnh khoảng cách */
@media (max-width: 480px) {
    .sim-timeline-wrap {
        padding: 0.5rem 0 0.75rem;
        gap: 12px;
    }
    .sim-timeline-inner {
        gap: 12px;
    }
    .sim-timeline-card {
        width: 115px;
        min-height: 195px;
        padding: 0.6rem 0.4rem;
    }
    .sim-timeline-card-num {
        font-size: 18px;
        margin-bottom: 0.35rem;
    }
    .sim-timeline-card-name {
        font-size: 12px;
        letter-spacing: 0.03em;
    }
    .sim-card-meaning-body-inner {
        font-size: 0.625rem;
        max-height: 220px;
    }
    .sim-accordion {
        border-radius: 0.75rem;
    }
    .sim-accordion-header {
        padding: 0.875rem 1rem;
        font-size: 0.9375rem;
        min-height: 48px;
        -webkit-tap-highlight-color: transparent;
    }
    .sim-accordion-body-inner {
        padding: 1rem 1rem 1.25rem;
        font-size: 0.875rem;
        line-height: 1.7;
    }
    .main-cta-btn {
        width: 100%;
        min-width: unset;
        padding: 1rem 1.5rem;
        font-size: 1rem;
        min-height: 52px;
        border-radius: 0.75rem;
    }
    .thailuu-ai-btn {
        width: 100%;
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
        min-height: 48px;
        border-radius: 0.75rem;
    }
    .pdf-export-btn {
        width: 100%;
        padding: 0.75rem 1.25rem;
        min-height: 48px;
        border-radius: 0.75rem;
    }
    #simResultSection .text-yellow-500.text-xl,
    #simResultSection .text-yellow-500.text-lg {
        font-size: 1rem;
        margin-bottom: 0.75rem;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .sim-timeline-card {
        width: 104px;
        min-height: 180px;
    }
    .sim-accordion-header {
        padding: 0.9375rem 1.125rem;
    }
}

.tab-navigation {
    gap: 1rem;
    padding-top: 0.75rem;
}

.tab-button {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: #ffffff;
    text-shadow: var(--text-shadow);
    border: var(--glass-border);
    padding: 0.6rem 1.2rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: var(--glass-shadow);
    font-family: Arial, sans-serif !important;
}
.tab-button:hover {
    background: rgba(255, 255, 255, 0.25);
    box-shadow: var(--glass-shadow);
}
.tab-button.active {
    background: var(--button-primary) !important;
    color: var(--button-primary-text) !important;
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    box-shadow: var(--glass-shadow);
}
.tab-button.active:hover {
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}

#thaiLuuBtn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    padding: 0.8rem 2rem;
    border-radius: var(--glass-radius);
    cursor: pointer;
    box-shadow: var(--glass-shadow);
    transition: all 0.3s;
    width: auto;
    margin-top: 1.5rem;
    font-size: 1.1rem;
}
#thaiLuuBtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}

#pdfBtn {
    background: #ef4444;
    color: #ffffff;
    border: 1px solid #dc2626;
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    padding: 0.6rem 1.2rem;
    border-radius: var(--glass-radius);
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}
#pdfBtn:hover {
    background: #dc2626;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}
#pdfBtn.sim-pdf-btn {
    background: linear-gradient(to right, #dc2626, #b91c1c);
    border-color: #b91c1c;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.35);
}
#pdfBtn.sim-pdf-btn:hover {
    background: linear-gradient(to right, #ef4444, #dc2626);
    border-color: #dc2626;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}

.tool-content {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border);
    padding: 1.5rem;
    border-radius: 0.75rem;
    box-shadow: var(--glass-shadow);
}

/* Input & Select (White Glass) */
input, select, textarea {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border);
    border-radius: 0.5rem;
    padding: 12px 16px;
    color: #ffffff;
    width: 100%;
    font-size: 1.05rem;
    font-family: Arial, sans-serif !important;
    text-shadow: var(--text-shadow);
    transition: border-color 0.2s, box-shadow 0.2s;
}
input::placeholder, textarea::placeholder { color: rgba(255, 255, 255, 0.7); }
input:focus, select:focus, textarea:focus {
    border-color: rgba(255, 255, 255, 0.5);
    outline: none;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
}

/* Custom styling for the Date Picker Modal */
.picker-modal {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex; justify-content: center; align-items: center;
    z-index: 2000; opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.picker-modal.active { opacity: 1; pointer-events: auto; }

.picker-content {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    padding: 2rem; border-radius: var(--glass-radius);
    border: var(--glass-border); width: 95%; max-width: 500px;
    box-shadow: var(--glass-shadow);
}

.custom-select {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: var(--text-primary); border: var(--glass-border);
    border-radius: 0.5rem; padding: 0.5rem; font-size: 1rem; text-align: center;
    width: 100%; height: 45px; cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.custom-select:focus { border-color: rgba(255, 255, 255, 0.5); outline: none; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2); }

.btn-apply {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    width: 100%; padding: 0.8rem;
    border-radius: var(--glass-radius); text-transform: uppercase;
    box-shadow: var(--glass-shadow);
    transition: all 0.2s;
}
.btn-apply:hover { transform: scale(1.02); box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35); }

/* Nút VỀ HIỆN TẠI - viền vàng nhẹ, hover sáng lên */
.btn-now-modal {
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: #F9FAFB;
    text-shadow: var(--text-shadow);
    border: 1px solid rgba(251, 191, 36, 0.4);
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    padding: 0.8rem;
    border-radius: var(--glass-radius);
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.btn-now-modal:hover {
    background: rgba(30, 41, 59, 0.85);
    border-color: rgba(251, 191, 36, 0.7);
    box-shadow: 0 0 16px rgba(251, 191, 36, 0.25), 0 4px 12px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}
.btn-now-modal:active { transform: translateY(0); }
.btn-now-modal i { color: #FBBF24; transition: color 0.3s ease; }
.btn-now-modal:hover i { color: #FCD34D; }

/* === KHU VỰC NHẬP LIỆU - Sang trọng & Huyền bí === */
/* 1. Tiêu đề (Labels): Vàng Kim, in đậm */
#cong-cu-container .tool-content label {
    color: #FBBF24 !important;
    font-weight: bold !important;
    letter-spacing: 1px;
    text-shadow: 0 0 12px rgba(251, 191, 36, 0.25);
}
#cong-cu-container .tool-content label i { color: #FBBF24 !important; }

/* 2. Đoạn trích dẫn (Quote): Xám bạc tối, nghiêng, nhẹ làm nền */
.input-section-quote {
    color: #9CA3AF !important;
    font-style: italic;
    font-weight: 300;
}

/* Ô Dương lịch + Ô Âm lịch - bán kính đường bao đồng nhất */
.time-display-box,
.time-display-box .trigger-input {
    border-radius: 0.5rem;
}

/* Trigger Input - nền đen mờ, viền xám tối, focus vàng cam phát sáng */
.trigger-input-container { position: relative; cursor: pointer; }
.trigger-input {
    cursor: pointer; font-weight: bold;
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid #4B5563 !important;
    color: #F9FAFB !important;
    padding-right: 40px; text-align: center;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.trigger-input:focus {
    border-color: #F59E0B !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
    outline: none;
}
.calendar-icon { position: absolute; right: 15px; top: 50%; transform: translateY(-50%); color: #F9FAFB; pointer-events: none; }

.select-large { font-size: 1.1rem; height: 54px; text-align: center; text-align-last: center; }
.select-large option { text-align: center; }

/* Input Container for Mic - 3. Ô nhập: nền đen mờ, chữ trắng sáng, viền xám tối, focus vàng cam */
.input-wrapper { position: relative; width: 100%; }
.question-input {
    width: 100%; padding: 14px 88px 14px 16px;
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid #4B5563 !important;
    border-radius: 0.5rem;
    color: #F9FAFB !important;
    font-size: 1rem; margin-top: 8px;
    font-family: Arial, sans-serif !important;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    resize: none; overflow-y: hidden;
    min-height: 54px; line-height: 1.5;
}
.question-input::placeholder { color: rgba(249, 250, 251, 0.6); }
.question-input:focus {
    border-color: #F59E0B !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
    outline: none;
}

/* 4. Nút Xóa & Micro - icon sáng (trắng/vàng) trên nền tối */
.clear-btn {
    position: absolute;
    top: 50%;
    right: 48px;
    transform: translateY(-50%);
    color: #F9FAFB;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #4B5563;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    z-index: 10;
}
.clear-btn i { font-size: 1rem; color: #F9FAFB; }
.clear-btn:hover {
    color: #FBBF24;
    background: rgba(251, 191, 36, 0.2);
    border-color: rgba(251, 191, 36, 0.5);
    box-shadow: 0 0 12px rgba(251, 191, 36, 0.25);
    transform: translateY(-50%) scale(1.05);
}
.clear-btn:hover i { color: #FBBF24; }
.clear-btn:active { transform: translateY(-50%) scale(0.95); }

.mic-btn {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    color: #F9FAFB;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #4B5563;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    z-index: 10;
}
.mic-btn i { font-size: 1.125rem; color: #F9FAFB; transition: transform 0.3s ease; }
.mic-btn:hover {
    color: #FBBF24;
    background: rgba(251, 191, 36, 0.2);
    border-color: rgba(251, 191, 36, 0.5);
    box-shadow: 0 0 12px rgba(251, 191, 36, 0.25);
    transform: translateY(-50%) scale(1.05);
}
.mic-btn:hover i { color: #FBBF24; }

.mic-btn:active { transform: translateY(-50%) scale(0.95); }

.mic-btn.listening {
    color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: rgba(239, 68, 68, 0.4);
    animation: pulse-red 1.5s infinite;
}

.mic-btn.listening:hover { background: rgba(239, 68, 68, 0.3) !important; }

.mic-btn.listening i { animation: mic-pulse 0.8s ease-in-out infinite; }

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
    100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

label { font-weight: 600; color: #ffffff; text-shadow: var(--text-shadow); margin-bottom: 0.4rem; display: block; font-size: 0.95rem; font-family: Arial, sans-serif !important; }

/* === VISUAL QUẺ (Glass) === */
#resultSection.visible,
#simResultSection.visible { animation: fadeIn 0.8s ease-out forwards; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.hexagram-container {
    display: flex; flex-direction: column; align-items: center;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    padding: 1.5rem; border-radius: var(--glass-radius); border: var(--glass-border);
    box-shadow: var(--glass-shadow); height: 100%;
    transition: filter 0.3s, box-shadow 0.3s;
}
.hexagram-container:hover {
    filter: brightness(1.05);
    box-shadow: var(--glass-shadow);
}
.hexagram-visual { width: 120px; margin-bottom: 0.5rem; display: flex; flex-direction: column; align-items: center; }
.hexagram-name {
    text-transform: uppercase; font-weight: bold; font-size: 1.25rem; margin-top: 0.5rem;
    color: #ffffff; text-shadow: var(--heading-shadow);
    white-space: nowrap; font-family: Arial, sans-serif !important;
}
.hexagram-meaning {
    text-align: left; font-size: 1rem; color: rgba(255, 255, 255, 0.95); line-height: 1.6;
    border-top: var(--glass-border); padding-top: 1rem; width: 100%;
    font-family: Arial, sans-serif !important;
    text-shadow: var(--text-shadow);
}
/* Chữ nhấn đậm luận giải - màu vàng cam nổi bật */
.meaning-highlight {
    color: #fcd34d;
    font-weight: 700;
    text-transform: uppercase;
    text-shadow: 0 0 8px rgba(252, 211, 77, 0.4);
    font-family: Arial, sans-serif !important;
}
.hexagram-meaning strong,
.hexagram-meaning b {
    font-weight: 700;
    color: #fcd34d;
    text-shadow: 0 0 8px rgba(252, 211, 77, 0.4);
}

/* === CHAT INTERFACE (Glass) === */
#chat-interface { margin-top: 2rem; border-top: var(--glass-border); padding-top: 1.5rem; }
#chat-history {
    position: relative;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: var(--text-primary); border: var(--glass-border);
    border-radius: 0.75rem; height: 400px; overflow-y: auto;
    padding: 1.5rem; margin-bottom: 1rem;
    display: flex; flex-direction: column; gap: 1.2rem;
    box-shadow: var(--glass-shadow);
}
.chat-msg {
    max-width: 95%; padding: 0.8rem 1.2rem; border-radius: 0.5rem;
    line-height: 1.7; font-size: 1rem; font-family: Arial, sans-serif !important;
    font-weight: 400; position: relative;
    border: var(--glass-border);
    color: #ffffff;
    text-shadow: var(--text-shadow);
    transition: filter 0.2s, box-shadow 0.2s;
}
.chat-msg:hover { filter: brightness(1.03); }
.chat-ai {
    align-self: flex-start;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border-left: 4px solid rgba(255, 255, 255, 0.5);
    color: #ffffff;
    text-shadow: var(--text-shadow);
}
.chat-ai strong, .chat-ai b {
    color: #fcd34d;
    font-weight: 700;
    text-shadow: 0 0 6px rgba(252, 211, 77, 0.35);
}
.chat-user {
    align-self: flex-end;
    background: rgba(255, 255, 255, 0.2);
    border: var(--glass-border);
    color: #ffffff;
    text-shadow: var(--text-shadow);
    font-weight: 500;
}

.chat-input-wrapper { display: flex; width: 100%; position: relative; align-items: flex-end; gap: 0.5rem; }

.chat-input-container { position: relative; flex: 1; display: flex; align-items: center; }

#chatInput {
    background: rgba(0, 0, 0, 0.4) !important;
    color: #F9FAFB !important;
    border: 1px solid #4B5563 !important;
    padding: 10px 88px 10px 12px; border-radius: 0.5rem;
    width: 100%; min-height: 50px; max-height: 200px;
    resize: none; overflow-y: auto; line-height: 1.5; font-size: 1rem;
    font-family: Arial, sans-serif !important;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
#chatInput:focus {
    border-color: #F59E0B !important;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
    outline: none;
}
#chatInput::placeholder { color: rgba(249, 250, 251, 0.6); }

.chat-clear-btn {
    position: absolute !important; right: 48px !important; bottom: 8px !important;
    width: 34px !important; height: 34px !important;
    top: auto !important; transform: none !important;
    color: #F9FAFB; background: rgba(0, 0, 0, 0.5) !important; border: 1px solid #4B5563 !important;
    border-radius: 50% !important; cursor: pointer; display: flex; align-items: center; justify-content: center;
    z-index: 10;
}
.chat-clear-btn i { font-size: 0.95rem; color: #F9FAFB; }
.chat-clear-btn:hover { color: #FBBF24; background: rgba(251, 191, 36, 0.2) !important; border-color: rgba(251, 191, 36, 0.5) !important; box-shadow: 0 0 12px rgba(251, 191, 36, 0.25); }
.chat-clear-btn:hover i { color: #FBBF24; }

.chat-mic-btn {
    position: absolute !important; right: 8px !important; bottom: 8px !important;
    width: 34px !important; height: 34px !important;
    color: #F9FAFB; background: rgba(0, 0, 0, 0.5) !important; border: 1px solid #4B5563 !important;
    border-radius: 50% !important;
}
.chat-mic-btn i { color: #F9FAFB; }
.chat-mic-btn:hover { color: #FBBF24; background: rgba(251, 191, 36, 0.2) !important; border-color: rgba(251, 191, 36, 0.5) !important; box-shadow: 0 0 12px rgba(251, 191, 36, 0.25); }
.chat-mic-btn:hover i { color: #FBBF24; }
.chat-mic-btn.listening { background: rgba(239, 68, 68, 0.3) !important; }

#sendBtn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 0 1.5rem; border-radius: var(--glass-radius); font-weight: bold;
    font-family: Arial, sans-serif !important;
    cursor: pointer; height: 50px; flex-shrink: 0; white-space: nowrap;
    box-shadow: var(--glass-shadow); transition: all 0.3s;
}
#sendBtn:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35); }

.contact-glow { animation: pulse-glow 3s infinite ease-in-out; }
@keyframes pulse-glow { 0%, 100% { box-shadow: var(--glass-shadow); border-color: rgba(255,255,255,0.3); } 50% { box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18); border-color: rgba(255, 255, 255, 0.45); } }
.cta-question { color: #ffffff; text-shadow: var(--text-shadow); }
.zalo-button {
    display: inline-block;
    background: linear-gradient(to right, #0084ff, #0066cc);
    color: #ffffff;
    padding: 0.6rem 1.5rem; border-radius: var(--glass-radius);
    font-weight: bold; font-family: Arial, sans-serif !important;
    text-decoration: none; border: 1px solid #0084ff;
    box-shadow: 0 4px 12px rgba(0, 132, 255, 0.3);
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}
.zalo-button:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0, 132, 255, 0.4); }
.zalo-button.zalo-btn-send-mode {
    animation: zalo-shake 2.5s ease-in-out infinite;
}
@keyframes zalo-shake {
    0%, 90%, 100% { transform: translateY(-2px) translateX(0); }
    92% { transform: translateY(-2px) translateX(-2px); }
    94% { transform: translateY(-2px) translateX(2px); }
    96% { transform: translateY(-2px) translateX(-2px); }
    98% { transform: translateY(-2px) translateX(2px); }
}
/* Nút Mời cà phê - tông vàng cam hài hòa với tổng thể, sọc chéo nhẹ, chữ rõ ràng */
.coffee-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #B45309 0%, #D97706 50%, #B45309 100%);
    color: #ffffff !important;
    padding: 0.65rem 1.5rem;
    border-radius: 9999px;
    font-weight: bold;
    font-family: Arial, sans-serif !important;
    text-decoration: none;
    border: 1px solid rgba(245, 158, 11, 0.5);
    box-shadow: 0 4px 14px rgba(180, 83, 9, 0.4), 0 1px 3px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
/* Sọc chéo nhẹ (vàng cam đậm / sáng) - không che chữ */
.coffee-button::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        -45deg,
        transparent 0px,
        transparent 5px,
        rgba(255, 255, 255, 0.07) 5px,
        rgba(255, 255, 255, 0.07) 10px
    );
    border-radius: inherit;
    pointer-events: none;
    z-index: 0;
}
.coffee-button::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
    z-index: 0;
}
.coffee-button > * { position: relative; z-index: 1; }
.coffee-button:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.4), 0 2px 8px rgba(0, 0, 0, 0.2);
    filter: brightness(1.08);
}
.coffee-button:active { transform: translateY(-1px) scale(1); }
.coffee-button i { color: #ffffff !important; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4); transition: transform 0.3s ease; }
.coffee-button:hover i { transform: scale(1.1); }

#qrModal {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex; justify-content: center; align-items: center;
    z-index: 1000; opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
#qrModal.active { opacity: 1; pointer-events: auto; }
.qr-content {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    padding: 2.5rem; border-radius: var(--glass-radius); border: var(--glass-border);
    text-align: center; max-width: 90%; width: 400px; position: relative;
    box-shadow: var(--glass-shadow);
}
.close-modal { position: absolute; top: 10px; right: 15px; color: #ffffff; text-shadow: var(--text-shadow); font-size: 1.5rem; cursor: pointer; line-height: 1; width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; }
.close-modal:hover { color: #ffffff; filter: brightness(1.1); }
.close-modal i { font-size: 1.5rem; }

/* History Card (Glass) */
.history-card {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: var(--glass-border);
    border-radius: 0.75rem;
    padding: 1rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    box-shadow: var(--glass-shadow);
}
.history-card:hover {
    filter: brightness(1.08);
    box-shadow: var(--glass-shadow);
    border-color: rgba(255, 255, 255, 0.4);
}
.history-time { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.25rem; text-shadow: var(--text-shadow); }
.history-question { font-weight: bold; color: #ffffff; margin-bottom: 0.5rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: var(--text-shadow); }
.history-result { color: #f59e0b; font-size: 0.9rem; text-shadow: var(--text-shadow); }
.btn-delete {
    position: absolute; top: 10px; right: 10px;
    color: #EF4444; background: none; border: none; font-size: 1.2rem; cursor: pointer; padding: 0 5px;
    z-index: 10;
}
.btn-delete:hover { color: #DC2626; transform: scale(1.1); }
.empty-history { text-align: center; color: var(--text-muted); font-style: italic; padding: 2rem; text-shadow: var(--text-shadow); font-family: Arial, sans-serif !important; }

/* Actions Row in Chat */
.chat-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 10px;
    border-top: var(--glass-border);
    padding-top: 8px;
}

/* Text-to-Speech Button */
.tts-btn {
    background: var(--button-primary);
    color: var(--button-primary-text);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: var(--glass-radius);
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    font-family: Arial, sans-serif !important;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-weight: 600;
    min-height: 36px;
    box-shadow: var(--glass-shadow);
}

.tts-btn .tts-label {
    font-size: 0.875rem;
    white-space: nowrap;
}

.tts-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}

.tts-btn:active {
    transform: translateY(0);
}

.tts-btn i {
    font-size: 0.875rem;
}

/* Speaking state */
.chat-msg.speaking {
    border-left: 4px solid #eab308;
    background: #FEF3C7 !important;
    animation: speaking-pulse 2s ease-in-out infinite;
}

@keyframes speaking-pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(234, 179, 8, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(234, 179, 8, 0);
    }
}

/* Notification (White Glass) */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    color: #ffffff;
    text-shadow: var(--text-shadow);
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    border: var(--glass-border);
    box-shadow: var(--glass-shadow);
    z-index: 10000;
    max-width: 350px;
    font-size: 0.9375rem;
    font-family: Arial, sans-serif !important;
    line-height: 1.5;
    border-left: 4px solid rgba(255, 255, 255, 0.6);
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification-info { border-left-color: #3b82f6; }
.notification-error { border-left-color: #ef4444; background: rgba(127, 29, 29, 0.4); }
.notification-success { border-left-color: rgba(255, 255, 255, 0.8); }

/* Improved Mic Button States */
.mic-btn.listening {
    color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.1) !important;
    animation: pulse-red 1.5s infinite;
}

.mic-btn.listening i {
    animation: mic-pulse 0.8s ease-in-out infinite;
}

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

/* Mobile TTS Button */
@media (max-width: 768px) {
    .tts-btn {
        padding: 0.5rem;
        font-size: 0.8125rem;
        min-height: 40px;
    }
    
    .tts-btn span {
        display: none;
    }
    
    .notification {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: 100%;
        transform: translateY(-100px);
    }
    
    .notification.show {
        transform: translateY(0);
    }
}

/* ============================================
   MOBILE OPTIMIZATION - Smartphone Friendly
   ============================================ */

@media (max-width: 768px) {
    /* Base Container */
    body {
        font-size: 16px; /* Prevent zoom on iOS */
        -webkit-text-size-adjust: 100%;
    }
    
    #cong-cu-container {
        padding: 1rem;
        margin: 0.5rem;
        border-radius: 0.75rem;
        max-width: 100%;
    }
    
    .app-mini-header {
        margin: -1rem -1rem 0.5rem -1rem;
        padding-left: 1rem;
    }
    
    /* Header */
    .app-header {
        margin: -1rem -1rem 1.5rem -1rem;
        padding: 0.75rem 1rem 1rem;
        border-radius: 0;
    }
    
    .app-title {
        font-size: 1.5rem !important;
    }
    
    .app-slogan {
        font-size: 0.875rem !important;
        margin-top: 0.5rem;
    }
    
    /* Navigation Tabs - 2 hàng, mỗi hàng 2 mục, cân đối tổng thể */
    #cong-cu-container .tab-navigation {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto auto;
        gap: 0.625rem;
        padding: 0.5rem 0 0.75rem;
        margin-bottom: 1rem;
        width: 100%;
        max-width: 100%;
        place-items: stretch;
    }
    
    #cong-cu-container .tab-navigation .tab-button {
        padding: 0.75rem 0.5rem;
        font-size: 0.8125rem;
        min-height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        text-align: center;
        white-space: normal;
        line-height: 1.25;
        box-sizing: border-box;
    }
    
    #cong-cu-container .tab-navigation .tab-button i {
        font-size: 0.875rem;
        margin-right: 0.375rem;
        flex-shrink: 0;
    }
    
    /* Tool Content */
    .tool-content {
        padding: 1rem;
        border-radius: 0.5rem;
    }
    
    .tool-content p {
        font-size: 0.875rem;
        line-height: 1.6;
        margin-bottom: 1rem;
    }
    
    /* Date Picker Section */
    .bg-gray-900\/50 {
        padding: 1rem !important;
    }
    
    .flex.flex-col.md\:flex-row {
        flex-direction: column;
        gap: 1rem;
    }
    
    .w-full.md\:w-1\/2 {
        width: 100%;
    }
    
    label {
        font-size: 0.8125rem;
        margin-bottom: 0.5rem;
    }
    
    .trigger-input,
    .bg-gray-800.border {
        height: 48px !important; /* Larger touch target */
        font-size: 1rem !important; /* Prevent zoom on iOS */
    }
    
    .calendar-icon {
        width: 24px;
        height: 24px;
        right: 12px;
    }
    
    /* Input Fields */
    .input-wrapper {
        margin-top: 0.5rem;
    }
    
    .question-input {
        min-height: 48px !important; /* Larger touch target */
        padding: 12px 88px 12px 14px !important;
        font-size: 1rem !important; /* Prevent zoom on iOS */
        line-height: 1.5;
    }
    
    .clear-btn {
        width: 40px;
        height: 40px;
        right: 48px;
    }
    
    .mic-btn {
        width: 40px;
        height: 40px;
        top: 50%;
        right: 8px;
        transform: translateY(-50%);
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .mic-btn i {
        font-size: 1.125rem;
    }
    
    /* Select Dropdowns */
    .select-large,
    .custom-select {
        height: 48px !important;
        font-size: 1rem !important; /* Prevent zoom */
        padding: 0.75rem;
    }
    
    /* Buttons */
    #gieoQueBtn {
        width: 100%;
        min-width: unset;
        padding: 1rem 1.5rem;
        font-size: 1rem;
        min-height: 52px; /* Large touch target */
        border-radius: 0.5rem;
    }
    
    #thaiLuuBtn {
        width: 100%;
        padding: 1rem 1.5rem;
        font-size: 1rem;
        min-height: 48px;
        margin-top: 1rem;
    }
    
    #sendBtn {
        min-height: 48px;
        padding: 0 1.5rem;
        font-size: 0.9375rem;
    }
    
    #pdfBtn {
        min-height: 44px;
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
    
    /* Result Section */
    #resultSection {
        margin-top: 1.5rem;
    }
    
    .grid.grid-cols-1.md\:grid-cols-2 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .hexagram-container {
        padding: 1rem;
        border-radius: 0.5rem;
    }
    
    .hexagram-visual {
        width: 100px;
        margin-bottom: 0.75rem;
    }
    
    .hexagram-name {
        font-size: 1rem;
        margin-top: 0.5rem;
    }
    
    .hexagram-meaning {
        font-size: 0.875rem;
        line-height: 1.6;
        padding-top: 0.75rem;
    }
    
    /* Chat Interface */
    #chat-interface {
        margin-top: 1.5rem;
        padding-top: 1rem;
    }
    
    #chat-history {
        height: 350px;
        padding: 1rem;
        font-size: 0.9375rem;
        border-radius: 0.5rem;
    }
    
    .chat-msg {
        padding: 0.75rem 1rem;
        font-size: 0.9375rem;
        line-height: 1.6;
        max-width: 90%;
    }
    
    .chat-input-wrapper {
        flex-direction: row;
        gap: 0.5rem;
        align-items: flex-end;
    }
    
    .chat-input-container {
        flex: 1;
        position: relative;
    }
    
    #chatInput {
        width: 100%;
        min-height: 48px;
        padding: 12px 88px 12px 12px;
        font-size: 1rem;
        border-radius: 0.5rem;
    }
    
    .chat-clear-btn {
        right: 48px !important;
        bottom: 7px !important;
    }
    
    .chat-mic-btn {
        position: absolute !important;
        right: 8px !important;
        bottom: 7px !important;
        width: 34px !important;
        height: 34px !important;
    }
    
    /* Date Picker Modal */
    .picker-modal {
        padding: 1rem;
    }
    
    .picker-content {
        width: 95%;
        max-width: 100%;
        padding: 1.25rem;
        border-radius: 0.75rem;
    }
    
    .picker-content h3 {
        font-size: 1.125rem;
    }
    
    .grid.grid-cols-3.gap-3 {
        gap: 0.5rem;
    }
    
    .grid.grid-cols-2.gap-4 {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .btn-apply,
    .btn-now-modal {
        min-height: 48px;
        padding: 0.875rem;
        font-size: 0.9375rem;
    }
    
    /* QR Modal */
    .qr-content {
        width: 95%;
        max-width: 100%;
        padding: 1.5rem;
        border-radius: 0.75rem;
    }
    
    .qr-content h3 {
        font-size: 1.125rem;
    }
    
    .close-modal {
        width: 36px;
        height: 36px;
        top: 8px;
        right: 12px;
    }
    
    /* History Cards */
    .history-card {
        padding: 0.875rem;
        margin-bottom: 0.75rem;
    }
    
    .history-time {
        font-size: 0.75rem;
    }
    
    .history-question {
        font-size: 0.9375rem;
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
        margin-bottom: 0.375rem;
    }
    
    .history-result {
        font-size: 0.875rem;
    }
    
    .btn-delete {
        width: 36px;
        height: 36px;
        font-size: 1.125rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Footer */
    footer {
        margin-top: 2rem;
        padding-top: 1.5rem;
        font-size: 0.875rem;
    }
    
    footer .flex.flex-wrap.justify-center.gap-4 {
        flex-direction: column;
        gap: 0.75rem;
        width: 100%;
    }
    
    .zalo-button,
    .coffee-button {
        width: 100%;
        padding: 0.875rem 1.25rem;
        font-size: 0.9375rem;
        min-height: 48px;
        text-align: center;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .zalo-button i,
    .coffee-button i {
        margin-right: 0.5rem;
    }
    
    /* Grid Layouts */
    .grid.grid-cols-1.md\:grid-cols-2.gap-6 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    /* Manual Hexagram Selection */
    .grid.grid-cols-1.md\:grid-cols-2.gap-6.mb-6 {
        grid-template-columns: 1fr;
        gap: 1rem;
        margin-bottom: 1rem;
    }
    
    /* Result Grid */
    .grid.grid-cols-1.md\:grid-cols-2 {
        grid-template-columns: 1fr;
    }
    
    /* Text Sizes */
    .text-sm {
        font-size: 0.8125rem;
    }
    
    .text-base {
        font-size: 0.9375rem;
    }
    
    .text-lg {
        font-size: 1rem;
    }
    
    /* Spacing Adjustments */
    .mb-8 {
        margin-bottom: 1.5rem;
    }
    
    .mb-6 {
        margin-bottom: 1.25rem;
    }
    
    .mb-4 {
        margin-bottom: 1rem;
    }
    
    .mb-10 {
        margin-bottom: 2rem;
    }
    
    /* Prevent text selection on buttons for better UX */
    button {
        -webkit-tap-highlight-color: rgba(139, 92, 246, 0.3);
        -webkit-touch-callout: none;
        user-select: none;
        touch-action: manipulation; /* Remove 300ms delay */
    }
    
    /* Smooth scrolling */
    * {
        -webkit-overflow-scrolling: touch;
    }
    
    /* Improve touch targets */
    a, button, input, select, textarea {
        min-height: 44px; /* Minimum touch target size */
    }
    
    /* Better spacing for mobile */
    .mb-8 {
        margin-bottom: 1.5rem !important;
    }
    
    /* Modal improvements */
    .picker-modal,
    #qrModal {
        padding: 0.5rem;
    }
    
    
    /* History list improvements */
    #historyList {
        max-height: 50vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Empty state */
    .empty-history {
        padding: 3rem 1rem;
        font-size: 0.875rem;
    }
    
    /* Improve readability */
    .text-gray-400 {
        font-size: 0.8125rem;
        line-height: 1.6;
    }
    
    /* Better form field spacing */
    .mb-6 {
        margin-bottom: 1.25rem !important;
    }
    
    /* Result section spacing */
    #resultSection.visible {
        margin-top: 1.5rem;
        padding: 1rem;
        border-radius: 0.5rem;
    }
}

/* Tablet Optimization */
@media (min-width: 481px) and (max-width: 768px) {
    #cong-cu-container {
        padding: 1.25rem;
    }
    
    header h2 {
        font-size: 2rem !important;
    }
    
    .tab-button {
        padding: 0.75rem 1.25rem;
    }
}

/* Desktop - Keep original styles */
@media (min-width: 769px) {
    /* Desktop styles remain unchanged */
}

/* ============================================
   LANDING PAGE STYLES
   Trang chủ Hệ sinh thái Dịch Lý
   ============================================ */

.landing-page {
    background-color: #0f172a;
    color: #fff;
    font-family: Arial, sans-serif !important;
}

/* Header */
.landing-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(15, 23, 42, 0.95);
    border-bottom: 1px solid rgba(245, 158, 11, 0.2);
    padding: 0.75rem 1rem;
}
.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fbbf24;
    text-decoration: none;
    letter-spacing: 0.05em;
}
.nav-menu {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}
.nav-menu .nav-link {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
}
.nav-menu .nav-link:hover {
    color: #f59e0b;
}
.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
    cursor: pointer;
}

/* Hero */
.hero {
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem 1rem;
    background: linear-gradient(180deg, #0f172a 0%, #111827 100%);
}
.hero-inner {
    max-width: 700px;
}
.hero-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}
.hero-slogan {
    font-size: clamp(1rem, 2.5vw, 1.35rem);
    color: #fcd34d;
    font-style: italic;
    margin-bottom: 2rem;
    font-weight: 400;
}
.hero-cta {
    display: inline-block;
    padding: 0.875rem 2rem;
    background: linear-gradient(to right, #f59e0b, #d97706);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    border-radius: 0.5rem;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
}
.hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.5);
}

/* About */
.about {
    padding: 4rem 1rem;
    max-width: 1200px;
    margin: 0 auto;
}
.about-inner {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    align-items: center;
}
.about-image-placeholder {
    aspect-ratio: 4/3;
    background: rgba(31, 41, 55, 0.8);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: #f59e0b;
}
.about-content .section-title {
    color: #f59e0b;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}
.about-text {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    margin-bottom: 1rem;
}
.about-link {
    color: #fbbf24;
    text-decoration: none;
    font-weight: 600;
}
.about-link:hover {
    text-decoration: underline;
}

/* Ecosystem */
.ecosystem {
    padding: 4rem 1rem;
    background: rgba(17, 24, 39, 0.5);
}
.ecosystem-inner {
    max-width: 1200px;
    margin: 0 auto;
}
.ecosystem .section-title {
    text-align: center;
    color: #f59e0b;
    margin-bottom: 2rem;
    font-size: 1.5rem;
}
.ecosystem-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}
.ecosystem-card {
    background: rgba(31, 41, 55, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 1.5rem;
    text-align: center;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.ecosystem-card-active {
    border-color: #f59e0b;
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.25);
}
.ecosystem-icon {
    font-size: 2.5rem;
    color: #f59e0b;
    margin-bottom: 0.75rem;
}
.ecosystem-card-title {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 0.5rem;
}
.ecosystem-desc {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1rem;
    line-height: 1.5;
}
.ecosystem-btn {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: linear-gradient(to right, #f59e0b, #d97706);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0.375rem;
    border: none;
    cursor: pointer;
    transition: opacity 0.2s;
}
.ecosystem-btn:hover {
    opacity: 0.9;
}
.ecosystem-btn-disabled {
    background: #6b7280 !important;
    color: #9ca3af !important;
    cursor: not-allowed;
    pointer-events: none;
}

/* Blog */
.blog {
    padding: 4rem 1rem;
    max-width: 1200px;
    margin: 0 auto;
}
.blog .section-title {
    text-align: center;
    color: #f59e0b;
    margin-bottom: 2rem;
    font-size: 1.5rem;
}
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.blog-card {
    background: rgba(31, 41, 55, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: border-color 0.2s;
}
.blog-card:hover {
    border-color: rgba(245, 158, 11, 0.3);
}
.blog-card-image {
    aspect-ratio: 16/9;
    background: rgba(55, 65, 81, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #f59e0b;
}
.blog-card-body {
    padding: 1rem;
}
.blog-card-title {
    font-size: 1rem;
    color: #fff;
    margin-bottom: 0.5rem;
}
.blog-card-excerpt {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
}

/* Footer */
.landing-footer {
    padding: 2rem 1rem;
    background: #111827;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}
.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
}
.footer-copy {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.75rem;
}
.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}
.footer-link {
    color: #f59e0b;
    text-decoration: none;
    font-size: 0.95rem;
}
.footer-link:hover {
    text-decoration: underline;
}

/* Landing - Responsive */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 0;
        right: 0;
        width: 260px;
        height: 100vh;
        background: #111827;
        flex-direction: column;
        padding: 4rem 1.5rem 1.5rem;
        gap: 1rem;
        transform: translateX(100%);
        transition: transform 0.3s;
        border-left: 1px solid rgba(245, 158, 11, 0.2);
    }
    .nav-menu-open {
        transform: translateX(0);
    }
    .nav-toggle {
        display: block;
    }
    .about-inner {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .about-image-placeholder {
        max-width: 320px;
        margin: 0 auto;
    }
    .ecosystem-grid {
        grid-template-columns: 1fr;
    }
    .blog-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .ecosystem-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}