
:root {
    
    --bg-app: #fdfcfa;
    --bg-sidebar: #f5f4ef;
    --bg-card: #ffffff;
    --bg-input: #ffffff;

    --text-primary: #1e1d1b;
    --text-secondary: #5f5e5b;
    --text-tertiary: #8b8a87;

    --border-light: #e8e6e1;
    --border-hover: #d2d0cb;

    --primary: #d97757;
    
    --primary-light: #fcf6f4;
    --accent: #6b7280;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.05);

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;

    --bg-body: #f5f4ef;
    --bg-hover: #f0efea;
}

[data-theme="dark"] {
    --bg-app: #1a1918;
    --bg-sidebar: #22211f;
    --bg-card: #272624;
    --bg-input: #2a2927;

    --text-primary: #e6e4df;
    --text-secondary: #a3a19d;
    --text-tertiary: #75736f;

    --border-light: #3d3b38;
    --border-hover: #4f4d4a;

    --primary: #d97757;
    --primary-light: rgba(217, 119, 87, 0.15);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.6);

    --bg-body: #22211f;
    --bg-hover: #2e2d2b;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-primary);
    background: var(--bg-app);
    height: 100vh;
    overflow: hidden;
    font-size: 15px;
    opacity: 0;
    
    transition: opacity 0.3s ease;
}

body.app-loaded {
    opacity: 1;
}

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

button {
    font-family: inherit;
    border: none;
    cursor: pointer;
    background: none;
}

.app-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    grid-template-rows: 60px 1fr;
    height: 100vh;
    overflow: hidden;
    
}

.app-header {
    grid-column: 1 / -1;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    z-index: 50;
}

.brand-area {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-size: 18px;
    color: var(--text-primary);
}

.main-nav {
    display: flex;
    gap: 8px;
    
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    height: 60px;
    align-items: center;
    z-index: 50;
    background: transparent;
}

.nav-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s;
}

.nav-tab svg {
    width: 16px;
    height: 16px;
}

.nav-tab:hover {
    background: var(--bg-sidebar);
    color: var(--text-primary);
}

.nav-tab.active {
    background: var(--primary-light);
    color: var(--primary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-scratchpad {
    background: #fef3c7;
    color: #92400e;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid #fde68a;
}

.btn-scratchpad:hover {
    background: #fde68a;
}

.btn-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

.btn-icon:hover {
    background: var(--bg-sidebar);
    color: var(--text-primary);
}

.app-sidebar {
    grid-row: 2;
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border-light);
    padding: 24px 16px;
    
    height: calc(100vh - 60px);
    
    overflow-y: auto;
    
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.sidebar-mobile-settings {
    display: none;
}

@media (max-width: 768px) {
    .sidebar-mobile-settings {
        display: block;
        flex-shrink: 0;
        padding: 12px 16px 20px;
        border-top: 1px solid var(--border-light);
        background: var(--bg-sidebar);
    }

    .sidebar-mobile-settings-label {
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        color: var(--text-tertiary);
        letter-spacing: 0.05em;
        margin-bottom: 10px;
    }

    .sidebar-mobile-settings-row {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
    }

    .sidebar-lang-pill {
        padding: 5px 12px;
        border-radius: 999px;
        border: 1.5px solid var(--border-light);
        background: var(--bg-card);
        color: var(--text-secondary);
        font-size: 12px;
        font-weight: 600;
        cursor: pointer;
        transition: border-color 0.15s, background 0.15s, color 0.15s;
        font-family: inherit;
    }

    .sidebar-lang-pill:hover,
    .sidebar-lang-pill.active {
        border-color: var(--primary);
        color: var(--primary);
        background: rgba(217, 119, 87, 0.08);
    }

    .sidebar-icon-btn {
        width: 36px;
        height: 36px;
        border-radius: 8px;
        border: 1.5px solid var(--border-light);
        background: var(--bg-card);
        color: var(--text-secondary);
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: border-color 0.15s, color 0.15s;
    }

    .sidebar-icon-btn:hover {
        border-color: var(--primary);
        color: var(--primary);
    }
}

.sidebar-section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 12px;
    letter-spacing: 0.05em;
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 24px;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 12px;
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border-left: 3px solid transparent;
}

.sidebar-item:hover {
    background: var(--primary-light);
    color: var(--primary);
    transform: translateX(4px);
}

.sidebar-item.active {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 700;
    border-left-color: var(--primary);
    box-shadow: 0 4px 12px rgba(234, 88, 12, 0.08);
}

.sidebar-item svg {
    transition: transform 0.2s;
    opacity: 0.8;
}

.sidebar-item.active svg {
    opacity: 1;
    transform: scale(1.1);
}

.badge-count {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-tertiary);
}

.app-main {
    grid-row: 2;
    grid-column: 2;
    background: var(--bg-app);
    overflow-y: auto;
    padding: 0;
    position: relative;
}

.view-header {
    margin-bottom: 32px;
}

.view-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 8px;
}

.view-subtitle {
    color: var(--text-secondary);
}

.search-container {
    margin-bottom: 32px;
    position: relative;
    max-width: 600px;
}

.search-input {
    width: 100%;
    padding: 14px 20px 14px 48px;
    font-size: 16px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
    transition: all 0.2s;
}

.search-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
}

.shortcut-hint {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--bg-sidebar);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    color: var(--text-tertiary);
    border: 1px solid var(--border-light);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.prompt-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 20px;
    transition: all 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
}

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

.card-tags {
    margin-bottom: 12px;
}

@media (min-width: 769px) {
    .app-layout.sidebar-hidden {
        grid-template-columns: 1fr;
    }

    .app-layout.sidebar-hidden .app-sidebar {
        display: none;
    }

    .app-layout.sidebar-hidden .app-main {
        grid-column: 1;
        padding: 0;
    }
}

.pc-topbar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 32px 28px 16px;
    border-bottom: none;
    background: transparent;
    height: auto;
}

.pc-topbar-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.pc-topbar-sep {
    display: none;
}

.pc-topbar-meta {
    font-size: 12px;
    color: var(--text-tertiary);
    white-space: nowrap;
    flex-shrink: 0;
    margin-left: auto;
}

.pc-cards-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px 28px;
}

.pc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 24px;
    margin-bottom: 4px;
}

.pcm-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: visible;
    transition: transform 0.2s var(--ease-spring), box-shadow 0.2s var(--ease-smooth), border-color 0.15s;
    cursor: default;
}

.pcm-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-hover);
}

[data-theme="dark"] .pcm-card:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

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

.pcm-category-badge {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 4px 10px;
    border-radius: 6px;
    background: #ffedd5;
    color: #9a3412;
}

[data-theme="dark"] .pcm-category-badge {
    background: rgba(154, 52, 18, 0.2);
    color: #fdba74;
}

.pcm-actions {
    display: flex;
    gap: 12px;
    color: var(--text-tertiary);
}

.pcm-action-btn {
    background: none;
    border: none;
    padding: 0;
    color: inherit;
    cursor: pointer;
    transition: color 0.15s, transform 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pcm-action-btn:hover {
    color: var(--primary);
    transform: scale(1.1);
}

.pcm-open-btn:hover {
    color: var(--primary);
}

.pcm-ai-launcher {
    position: relative;
}

.pcm-ai-menu {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    z-index: 200;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    min-width: 160px;
    padding: 6px;
    flex-direction: column;
    gap: 2px;
}

.pcm-ai-menu.open {
    display: flex;
}

.pcm-ai-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    text-align: left;
    min-height: unset;
    transition: background 0.13s;
    white-space: nowrap;
}

.pcm-ai-option:hover {
    background: var(--bg-body);
}

.pcm-ai-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex-shrink: 0;
}

.guide-progress {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-tertiary);
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    padding: 3px 10px;
    border-radius: 999px;
    white-space: nowrap;
    flex-shrink: 0;
}

.pcm-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
    margin: 0 0 12px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pcm-snippet {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0 0 24px 0;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pcm-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
}

.pcm-tag {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-tertiary);
    background: var(--bg-body);
    padding: 3px 8px;
    border-radius: 4px;
    white-space: nowrap;
}

.pc-empty {
    padding: 100px 20px;
    text-align: center;
    color: var(--text-tertiary);
}

.pc-empty-icon {
    font-size: 40px;
    margin-bottom: 14px;
    opacity: 0.35;
}

.pc-empty-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.pc-empty-sub {
    font-size: 12px;
}

.pc-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 24px 0 4px;
    flex-wrap: wrap;
}

.pag-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-light);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: border-color 0.12s, color 0.12s;
    font-family: inherit;
}

.pag-btn:hover:not([disabled]) {
    border-color: var(--primary);
    color: var(--primary);
}

.pag-btn.off,
.pag-btn[disabled] {
    opacity: 0.3;
    cursor: not-allowed;
}

.pag-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 4px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    transition: background 0.12s, color 0.12s, border-color 0.12s;
}

.pag-num:hover:not(.active) {
    background: var(--bg-sidebar);
    color: var(--text-primary);
}

.pag-num.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    font-weight: 600;
}

.pag-sep {
    font-size: 13px;
    color: var(--text-tertiary);
    width: 24px;
    text-align: center;
    line-height: 32px;
    user-select: none;
}

.pag-info {
    font-size: 11px;
    color: var(--text-tertiary);
    margin-left: 10px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.tag {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    margin-right: 6px;
}

.tag.health {
    background: #fee2e2;
    color: #991b1b;
}

.tag.business {
    background: #ffedd5;
    color: #9a3412;
}

.tag.coding {
    background: #e0e7ff;
    color: #3730a3;
}

.tag.default {
    background: #f3f4f6;
    color: #4b5563;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.4;
}

.card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-actions {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lab-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    height: calc(100vh - 140px);
}

.lab-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
}

.panel-header {
    padding: 16px;
    border-bottom: 1px solid var(--border-light);
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-sidebar);
}

.lab-input,
.lab-output {
    flex: 1;
    padding: 20px;
    border: none;
    resize: none;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    background: var(--bg-input);
    color: var(--text-primary);
}

.lab-output {
    background: var(--bg-sidebar);
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
}

.modal-overlay.open {
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    background: var(--bg-card);
    width: 600px;
    max-height: 80vh;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.app-footer {
    padding: 64px 24px;
    text-align: center;
    border-top: 1px solid var(--border-light);
    margin-top: 60px;
    background: var(--bg-app);
}

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

.footer-icon-link {
    color: var(--text-tertiary);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-icon-link:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

.footer-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.footer-desc {
    color: var(--text-secondary);
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}

.footer-sep {
    color: var(--text-tertiary);
    opacity: 0.5;
}

.footer-brand-link {
    color: var(--text-primary);
    font-weight: 600;
    transition: color 0.2s;
    display: inline-flex;
    align-items: center;
}

.footer-brand-link:hover {
    color: var(--primary);
}

.footer-bottom {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-tertiary);
    letter-spacing: 0.1em;
    opacity: 0.8;
}

@media (max-width: 1024px) {
    .app-layout {
        grid-template-columns: 240px 1fr;
    }
}

@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    .app-layout {
        grid-template-columns: 1fr;
        grid-template-rows: 52px 1fr;
    }

    .app-header {
        padding: 0 16px;
        height: 52px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .mobile-menu-toggle {
        display: none !important;
    }

    .brand-area span[data-i18n="header.platform"] {
        display: none;
    }

    .brand-area {
        gap: 8px;
    }

    .brand-text {
        font-size: 15px;
        font-weight: 700;
    }

    .header-actions {
        display: flex;
        align-items: center;
        gap: 4px;
    }

    #offline-indicator,
    #pwa-install-btn {
        display: none !important;
    }

    .main-nav {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        transform: none;
        height: auto;
        background: var(--bg-card);
        border-top: 1px solid var(--border-light);
        box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.06);
        display: flex;
        justify-content: space-around;
        align-items: stretch;
        padding: 6px 4px env(safe-area-inset-bottom, 0px);
        z-index: 200;
    }

    .nav-tab {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        font-size: 10px;
        padding: 4px 6px;
        min-width: 52px;
        min-height: 44px;
        border-radius: var(--radius-sm);
    }

    .nav-tab svg {
        width: 22px !important;
        height: 22px !important;
        margin: 0 !important;
    }

    .nav-tab.active {
        color: var(--primary);
        background: var(--primary-light);
    }

    .app-sidebar {
        display: none;
    }

    .app-main {
        grid-column: 1;
        padding: 0 0 72px 0;
    }

    .cards-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .view-title {
        font-size: 24px;
    }

    .search-container {
        max-width: 100%;
    }

    .shortcut-hint {
        display: none;
    }

    .footer-desc {
        flex-direction: column;
        gap: 12px;
    }

    .footer-sep {
        display: none;
    }

    .pc-topbar {
        padding: 16px;
        height: auto;
        flex-wrap: wrap;
    }

    .pc-search-wrap {
        order: 3;
        width: 100%;
        max-width: 100%;
        margin-top: 12px;
    }

    .pc-cards-scroll {
        padding: 16px;
    }
}

.hidden {
    display: none !important;
}

*:focus {
    outline: none;
}

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

body {
    font-size: 15px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.app-main,
.app-sidebar,
.prompts-nav,
.pc-cards-scroll {
    scroll-behavior: smooth;
}

::selection {
    background: var(--primary);
    color: #fff;
}

button,
[role="button"],
.sidebar-item,
.nav-tab,
.pag-btn,
.pag-num {
    min-height: 36px;
    cursor: pointer;
}

button,
[role="button"] {
    min-height: 40px;
}

.app-header {
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-card);
    
    box-shadow: none;
}

[data-theme="dark"] .app-header {
    background: var(--bg-card);
}

.brand-area svg:first-of-type {
    color: var(--primary);
}

.brand-area {
    font-weight: 800;
    letter-spacing: -0.3px;
}

.mobile-menu-toggle {
    display: none;
}

.nav-tab {
    padding: 7px 14px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
    gap: 6px;
    min-height: 36px;
}

.nav-tab:hover {
    background: var(--bg-sidebar);
    color: var(--text-primary);
}

.nav-tab.active {
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(234, 88, 12, 0.30);
}

[data-theme="dark"] .nav-tab.active {
    box-shadow: 0 2px 10px rgba(249, 115, 22, 0.35);
}

.btn-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    transition: background 0.15s, color 0.15s;
}

.app-sidebar {
    padding: 20px 16px;
}

.sidebar-section-title {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-tertiary);
    letter-spacing: 0.08em;
    margin-bottom: 8px;
    padding: 0 6px;
    margin-top: 16px;
}

.sidebar-section-title:first-child {
    margin-top: 0;
}

.sidebar-menu {
    gap: 2px;
}

.sidebar-item {
    padding: 9px 12px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: background 0.15s, color 0.15s, padding-left 0.15s;
}

.sidebar-item:hover {
    background: rgba(234, 88, 12, 0.06);
    color: var(--text-primary);
    padding-left: 14px;
}

.sidebar-item.active {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
    box-shadow: none;
    border-left: 3px solid var(--primary);
    padding-left: 9px;
}

[data-theme="dark"] .sidebar-item.active {
    background: rgba(249, 115, 22, 0.12);
    color: var(--primary);
}

.badge-count {
    font-size: 11px;
    font-weight: 600;
    background: var(--bg-app);
    color: var(--text-tertiary);
    padding: 1px 6px;
    border-radius: 10px;
    border: 1px solid var(--border-light);
}

.hero-heading {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 48px;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    line-height: 1.1;
    margin-bottom: 16px;
}

.hero-heading span.accent {
    color: var(--primary);
}

.home-stats-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 28px auto 56px;
    max-width: 560px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.home-stat {
    flex: 1;
    padding: 16px 20px;
    text-align: center;
    position: relative;
}

.home-stat+.home-stat::before {
    content: '';
    position: absolute;
    left: 0;
    top: 20%;
    bottom: 20%;
    width: 1px;
    background: var(--border-light);
}

.home-stat-value {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 28px;
    font-weight: 400;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -0.3px;
}

.home-stat-label {
    font-size: 12px;
    color: var(--text-tertiary);
    font-weight: 500;
    margin-top: 2px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.home-feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
}

.home-feature-card::before {
    display: none;
    
}

.home-feature-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.10);
    border-color: var(--border-hover);
}

[data-theme="dark"] .home-feature-card:hover {
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.40);
}

.home-feature-card .card-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    flex-shrink: 0;
}

.home-feature-card h3 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.home-feature-card p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.65;
    margin-bottom: 20px;
    flex: 1;
}

.home-feature-card .card-cta {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 2px;
    transition: gap 0.15s;
}

.home-feature-card:hover .card-cta {
    gap: 8px;
    border-bottom-color: var(--primary);
}

.home-cta-banner {
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 44px 40px;
    text-align: center;
    box-shadow: none;
}

.home-cta-banner::before {
    display: none;
}

.home-cta-banner h3 {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 10px;
    color: var(--text-primary);
    letter-spacing: -0.3px;
}

.home-cta-banner p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.home-cta-banner .tag-row {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.lang-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    font-size: 14px;
    font-weight: 600;
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    border-radius: 999px;
    color: var(--text-primary);
    transition: background 0.15s, border-color 0.15s;
}

.lang-tag:hover {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
}

.pc-search-wrap input {
    padding: 9px 14px 9px 34px;
    font-size: 14px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border-light);
}

.pc-search-wrap input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
    outline: none;
}

.pc-card {
    border-radius: var(--radius-lg);
    padding: 18px 18px 14px;
    transition: box-shadow 0.18s, border-color 0.18s, transform 0.18s;
}

.pc-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.09);
}

[data-theme="dark"] .pc-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.pc-card::after {
    width: 4px;
    border-radius: 0 0 0 var(--radius-lg);
}

.pag-btn,
.pag-num {
    width: 38px;
    height: 38px;
    min-height: 38px;
    font-size: 14px;
    border-radius: var(--radius-md);
}

.pag-btn:hover:not([disabled]) {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary);
}

.pag-num.active {
    box-shadow: 0 2px 6px rgba(234, 88, 12, 0.30);
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: box-shadow 0.18s, border-color 0.18s, transform 0.18s;
    cursor: pointer;
}

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

[onclick],
[role="button"],
.card,
.sidebar-item,
.home-feature-card,
.prompt-card {
    cursor: pointer;
}

button {
    min-height: unset;
    
    transition: opacity 0.15s, background 0.15s, color 0.15s, transform 0.15s, box-shadow 0.15s;
}

.btn-scratchpad {
    min-height: 36px;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 600;
    transition: background 0.15s, transform 0.1s;
}

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

.view-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 36px;
    font-weight: 400;
    letter-spacing: -0.4px;
    line-height: 1.2;
    color: var(--text-primary);
}

.view-subtitle {
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-secondary);
    margin-top: 6px;
}

.card-title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
}

.card-desc {
    font-size: 14px;
    line-height: 1.65;
}

.pc-topbar-title {
    font-size: 15px;
    font-weight: 700;
}

#tools-grid .card {
    display: flex;
    flex-direction: column;
}

#tools-grid .card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
}

[data-theme="dark"] #tools-grid .card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.40);
}

[data-theme="dark"] .home-stats-bar {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .home-feature-card::before {
    opacity: 0.85;
}

[data-theme="dark"] .lang-tag {
    background: var(--bg-input);
    border-color: var(--border-light);
}

[data-theme="dark"] .lang-tag:hover {
    background: rgba(249, 115, 22, 0.12);
    border-color: var(--primary);
    color: var(--primary);
}

@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    .home-stats-bar {
        flex-direction: row;
        border-radius: var(--radius-md);
        margin: 20px auto 40px;
    }

    .home-stat {
        padding: 12px 10px;
    }

    .home-stat-value {
        font-size: 18px;
    }

    .home-stat-label {
        font-size: 10px;
    }

    .hero-heading {
        font-size: 32px;
    }

    .home-feature-card {
        padding: 22px 18px;
    }

    .home-cta-banner {
        padding: 28px 20px;
    }

    .home-cta-banner h3 {
        font-size: 20px;
    }

    .pag-btn,
    .pag-num {
        width: 42px;
        height: 42px;

        min-height: 42px;
    }

    .nav-tab {
        border-radius: var(--radius-sm);
        padding: 4px 6px;
        min-height: 48px;
    }
}

@media (max-width: 480px) {
    .home-stats-bar {
        flex-direction: column;
        border-radius: var(--radius-md);
    }

    .home-stat+.home-stat::before {
        left: 16px;
        right: 16px;
        width: auto;
        height: 1px;
        top: 0;
        bottom: auto;
    }
}

.view-section {
    animation: fadeInView 0.18s ease;
}

@keyframes fadeInView {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.guide-container {
    padding: 40px 60px;
    max-width: 1100px;
    margin: 0 auto;
}

.guide-title-row {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 32px;
}

.guide-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0;
}

.guide-layout {
    display: flex;
    gap: 24px;
}

.guide-tabs {
    flex-shrink: 0;
    width: 280px;
    display: flex;
    flex-direction: column;
}

.guide-tab-item {
    padding: 16px 20px;
    margin-bottom: 8px;
    background: var(--bg-card);
    color: var(--text-primary);
    border: 2px solid var(--border-light);
    border-left: 2px solid var(--border-light);
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 12px;
}

.guide-tab-item:hover:not(.active) {
    background: var(--bg-hover);
    border-color: var(--primary);
}

.guide-tab-item.active {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary);
    border-left: 6px solid var(--primary);
    font-weight: 700;
}

.guide-tab-num {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
    transition: all 0.2s;
}

.guide-tab-item.active .guide-tab-num {
    background: var(--primary);
    color: white;
}

.guide-tab-text {
    flex: 1;
    line-height: 1.4;
}

.guide-content-area {
    flex: 1;
    background: var(--bg-card);
    border: 2px solid var(--border-light);
    border-radius: 12px;
    padding: 32px;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.guide-watermark {
    position: absolute;
    top: 20px;
    right: 20px;
    color: var(--border-hover);
    opacity: 0.15;
    pointer-events: none;
}

.guide-inner-content {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    position: relative;
    z-index: 2;
}

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

.timeline-wrapper {
    position: relative;
    padding-left: 200px;
    margin-top: 24px;
}

.timeline-line {
    position: absolute;
    left: 160px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-light);
}

.timeline-item {
    position: relative;
    margin-bottom: 48px;
}

.timeline-label {
    position: absolute;
    left: -200px;
    top: 0;
    width: 140px;
    text-align: right;
}

.timeline-year {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
}

.timeline-period {
    font-size: 12px;
    color: var(--text-tertiary);
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.timeline-dot {
    position: absolute;
    left: -46px;
    top: 4px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary);
    border: 3px solid var(--bg-app);
    z-index: 2;
    box-sizing: content-box;
}

.timeline-content {
    padding-left: 24px;
}

.timeline-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.timeline-desc {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    margin: 0;
}

.page-hero-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 24px 32px;
    margin-bottom: 24px;
    display: flex;
    gap: 20px;
    align-items: center;
    box-shadow: var(--shadow-sm);
}

.page-hero-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.page-hero-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 24px;
    font-weight: 400;
    color: var(--text-primary);
    margin-bottom: 6px;
    letter-spacing: -0.3px;
}

.page-hero-sub {
    font-size: 15px;
    color: var(--text-secondary);
    max-width: 700px;
    line-height: 1.5;
    margin: 0;
}

@media (max-width: 768px) {
    .guide-page>div:first-child {
        padding: 12px 12px 0 !important;
    }

    .guide-container {
        padding: 12px 12px 80px;
    }

    .guide-title-row {
        margin-bottom: 12px;
    }

    .guide-title {
        font-size: 20px;
        margin-bottom: 0;
    }

    .guide-progress {
        font-size: 11px;
    }

    .guide-layout {
        flex-direction: column;
        gap: 10px;
    }

    .guide-tabs {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        overflow: visible;
        gap: 8px;
        padding-bottom: 4px;
    }

    .guide-tab-item {
        flex-shrink: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0;
        margin-bottom: 0;
        margin-right: 0;
        border-left: none;
        border-radius: 50%;
        border: 1.5px solid var(--border-light);
        background: var(--bg-card);
        width: 36px;
        height: 36px;
        min-height: unset;
    }

    .guide-tab-text {
        display: none;
    }

    .guide-tab-num {
        width: 28px;
        height: 28px;
        min-width: 28px;
        font-size: 12px;
        border-radius: 50%;
        background: transparent;
        color: var(--text-secondary);
    }

    .guide-tab-item.active {
        border-color: var(--primary);
        background: var(--primary-light);
        border-left: 1.5px solid var(--primary);
    }

    .guide-tab-item.active .guide-tab-num {
        background: var(--primary);
        color: #fff;
    }

    .guide-content-area {
        padding: 16px;
        overflow: visible;
        border-radius: 10px;
    }

    .guide-watermark {
        display: none;
    }

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

    .timeline-wrapper {
        padding-left: 24px;
    }

    .timeline-line {
        left: 6px;
    }

    .timeline-label {
        position: relative;
        left: 0;
        width: 100%;
        text-align: left;
        padding-left: 24px;
        margin-bottom: 12px;
    }

    .timeline-dot {
        left: -2px;
    }

    .timeline-content {
        padding-left: 24px;
    }
}

.lang-switcher {
    position: relative;
}

.lang-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    min-width: 160px;
    z-index: 200;
    overflow: hidden;
    animation: fadeInDown 0.15s ease;
}

.lang-dropdown.open {
    display: block;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 0.12s, color 0.12s;
}

.lang-option:hover {
    background: var(--bg-sidebar);
    color: var(--text-primary);
}

.lang-option.active {
    color: var(--primary);
    font-weight: 700;
    background: var(--primary-light);
}

.lang-flag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 20px;
    border-radius: 6px;
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.4px;
    line-height: 1;
}

.sidebar-quick-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: var(--radius-sm);
    margin: 0 4px;
    transition: background 0.15s, color 0.15s, padding-left 0.15s;
}

.sidebar-quick-link:hover {
    background: var(--primary-light);
    color: var(--primary);
    padding-left: 20px;
}

.sidebar-quick-link svg {
    flex-shrink: 0;
    opacity: 0.7;
}

.sidebar-quick-link:hover svg {
    opacity: 1;
}

.sidebar-tip-box {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-left: 4px solid var(--primary);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.sidebar-tip-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 6px;
}

.sidebar-tip-text {
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-secondary);
    margin: 0;
}

[data-theme="dark"] .sidebar-tip-box {
    background: rgba(249, 115, 22, 0.08);
}

.about-page {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.about-hero {
    background: var(--bg-card);
    padding: 40px 24px 32px;
    text-align: center;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-light);
}

.about-hero-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    color: var(--primary);
    box-shadow: none;
}

.about-hero-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 42px;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    line-height: 1.15;
    margin-bottom: 12px;
}

.about-hero-sub {
    font-size: 18px;
    font-weight: 400;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 24px;
}

.about-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 12px 8px;
    gap: 0;
}

.about-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 0 20px;
}

.about-stat-num {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 28px;
    font-weight: 400;
    color: var(--text-primary);
    line-height: 1;
}

.about-stat-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.about-stat-divider {
    width: 1px;
    height: 36px;
    background: var(--border-light);
    flex-shrink: 0;
}

.about-pillars-section {
    background: var(--bg-app);
    padding: 32px 24px;
}

.about-pillars {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

.about-pillar {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: all 0.2s ease;
}

.about-pillar:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-hover);
}

.about-pillar-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    flex-shrink: 0;
}

.about-pillar-icon-wrap--orange {
    color: var(--primary);
}

.about-pillar-icon-wrap--indigo {
    color: var(--accent);
}

.about-pillar-icon-wrap--sky {
    color: #0ea5e9;
}

.about-pillar-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 4px;
}

.about-pillar-text {
    font-size: 13px;
    line-height: 1.65;
    color: var(--text-secondary);
    flex-grow: 1;
}

.about-creator-section {
    background: var(--bg-app);
    padding: 32px 24px 48px;
}

.about-creator-card {
    display: flex;
    flex-direction: column;
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 36px 48px;
    transition: all 0.2s ease;
}

.about-creator-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-md);
}

.about-creator-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.about-creator-socials {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 12px;
}

.about-social-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    transition: all 0.2s ease;
    text-decoration: none;
}

.about-social-link:hover {
    color: var(--text-primary);
    background: var(--bg-card);
    border-color: var(--border-hover);
}

.about-creator-name {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
    margin-top: 2px;
}

.about-creator-role {
    font-size: 15px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: -4px;
}

.about-creator-bio {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-top: 4px;
}

.about-creator-quote {
    position: relative;
    margin-top: 24px;
    padding: 16px 20px;
    border-radius: var(--radius-md);
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    font-style: normal;
}

.about-quote-mark {
    display: block;
    font-family: Georgia, serif;
    font-size: 48px;
    line-height: 0.8;
    color: var(--border-hover);
    font-weight: 900;
    margin-bottom: 4px;
    user-select: none;
}

.about-quote-text {
    display: block;
    font-size: 14px;
    font-style: italic;
    line-height: 1.65;
    color: var(--text-secondary);
    font-weight: 400;
}

.about-quote-accent {
    display: none;
}

@media (max-width: 768px) {

    .about-hero {
        padding: 32px 16px 24px;
    }

    .about-hero-title {
        font-size: 28px;
    }

    .about-hero-sub {
        font-size: 16px;
    }

    .about-stats {
        gap: 12px 0;
        flex-wrap: wrap;
        padding: 16px 4px;
    }

    .about-stat {
        padding: 4px 16px;
        min-width: 50%;
    }

    .about-stat-divider {
        display: none;
    }

    .about-pillars-section {
        padding: 24px 16px;
    }

    .about-pillars {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .about-pillar {
        padding: 16px 20px;
    }

    .about-creator-section {
        padding: 24px 16px 32px;
    }

    .about-creator-card {
        padding: 24px;
    }

    .about-social-link {
        padding: 6px 10px;
        font-size: 12px;
    }

    .about-creator-name {
        font-size: 22px;
    }
}

:root {
    --primary-hover: #c4653e;
    --primary-glow: rgba(217, 119, 87, 0.18);
    --shadow-glow: 0 0 0 3px var(--primary-glow);
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06);
    --shadow-elevated: 0 8px 24px rgba(0, 0, 0, 0.10), 0 2px 6px rgba(0, 0, 0, 0.06);
    --font-code: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --code-bg: #1e1c1a;
    --code-fg: #e8e4de;
}

[data-theme="dark"] {
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.25), 0 4px 16px rgba(0, 0, 0, 0.35);
    --shadow-elevated: 0 8px 32px rgba(0, 0, 0, 0.50);
    --code-bg: #111110;
    --code-fg: #cdc7be;
}

::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-hover);
    border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-tertiary);
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--border-hover) transparent;
}

.app-header {
    backdrop-filter: blur(20px) saturate(1.4);
    -webkit-backdrop-filter: blur(20px) saturate(1.4);
}

.brand-area {
    font-weight: 800;
    font-size: 17px;
    letter-spacing: -0.4px;
}

.brand-area .brand-text {
    background: linear-gradient(135deg, var(--text-primary) 30%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-tab.active {
    box-shadow: 0 2px 12px var(--primary-glow), 0 0 0 1px rgba(217, 119, 87, 0.15);
}

.app-sidebar {
    padding: 16px 12px;
}

.sidebar-section-title {
    font-size: 10px;
    letter-spacing: 0.1em;
    padding: 0 10px;
    margin-top: 20px;
}

.sidebar-section-title:first-child {
    margin-top: 4px;
}

.sidebar-item {
    font-size: 13.5px;
    font-weight: 450;
    padding: 8px 10px;
    border-radius: var(--radius-md);
    transition: background 0.15s, color 0.15s, padding-left 0.15s;
}

.sidebar-item:hover {
    background: var(--primary-glow);
    color: var(--primary);
    padding-left: 14px;
}

.sidebar-item.active {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
    border-left: 2px solid var(--primary);
    padding-left: 8px;
}

.home-feature-card {
    border-radius: 18px;
    transition: transform 0.25s var(--ease-spring), box-shadow 0.25s var(--ease-smooth), border-color 0.2s;
    position: relative;
}

.home-feature-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top left, var(--primary-glow) 0%, transparent 65%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    border-radius: inherit;
}

.home-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-elevated);
    border-color: rgba(217, 119, 87, 0.25);
}

.home-feature-card:hover::after {
    opacity: 1;
}

.home-feature-card .card-icon {
    border: 1px solid var(--border-light);
    background: var(--bg-sidebar);
}

.home-feature-card h3 {
    letter-spacing: -0.25px;
}

.hero-heading {
    font-size: 52px;
    font-weight: 400;
    letter-spacing: -0.8px;
    line-height: 1.08;
}

.hero-heading .accent {
    color: var(--primary);
    font-style: italic;
}

.guide-tabs {
    width: 264px;
    gap: 2px;
}

.guide-tab-item {
    padding: 10px 14px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text-secondary);
    gap: 10px;
    margin-bottom: 2px;
    transition: background 0.15s, color 0.15s, border-color 0.15s, padding-left 0.15s;
}

.guide-tab-item:hover:not(.active) {
    background: var(--bg-sidebar);
    color: var(--text-primary);
    border-color: var(--border-light);
}

.guide-tab-item.active {
    background: var(--primary-light);
    color: var(--primary);
    border-color: rgba(217, 119, 87, 0.2);
    border-left: 3px solid var(--primary);
    font-weight: 600;
    padding-left: 11px;
}

[data-theme="dark"] .guide-tab-item.active {
    background: rgba(217, 119, 87, 0.1);
    border-color: rgba(217, 119, 87, 0.25);
}

.guide-tab-num {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    background: var(--bg-sidebar);
    color: var(--text-tertiary);
    border: 1px solid var(--border-light);
    transition: background 0.15s, color 0.15s;
}

.guide-tab-item.active .guide-tab-num {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.guide-content-area {
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 36px 40px;
    box-shadow: var(--shadow-card);
}

.guide-inner-content {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.75;
}

.guide-inner-content>*:first-child {
    margin-top: 0 !important;
}

.guide-inner-content h2 {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 23px;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: -0.35px;
    line-height: 1.3;
    margin: 32px 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-light);
}

.guide-inner-content h3 {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: var(--primary);
    margin: 24px 0 8px;
}

.guide-inner-content h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 20px 0 6px;
}

.guide-inner-content p {
    margin-bottom: 14px;
    line-height: 1.78;
}

.guide-inner-content strong {
    color: var(--text-primary);
    font-weight: 600;
}

.guide-inner-content ul,
.guide-inner-content ol {
    padding-left: 20px;
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.guide-inner-content ul {
    list-style: none;
    padding-left: 0;
}

.guide-inner-content ul li {
    position: relative;
    padding-left: 20px;
    line-height: 1.65;
}

.guide-inner-content ul li::before {
    content: '–';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: 600;
}

.guide-inner-content ol {
    list-style: decimal;
}

.guide-inner-content ol li {
    line-height: 1.65;
    padding-left: 4px;
}

.guide-inner-content ol li::marker {
    color: var(--primary);
    font-weight: 600;
}

.guide-inner-content a {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.guide-inner-content pre {
    background: var(--code-bg);
    color: var(--code-fg);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    font-family: var(--font-code);
    font-size: 12.5px;
    line-height: 1.7;
    margin: 16px 0 20px;
    overflow-x: auto;
    border: 1px solid rgba(255, 255, 255, 0.06);
    white-space: pre-wrap;
    word-break: break-word;
}

[data-theme="dark"] .guide-inner-content pre {
    background: rgba(0, 0, 0, 0.35);
    border-color: var(--border-light);
}

.guide-inner-content code:not(pre code) {
    background: var(--bg-sidebar);
    border: 1px solid var(--border-light);
    border-radius: 4px;
    padding: 1px 6px;
    font-family: var(--font-code);
    font-size: 12px;
    color: var(--primary);
}

.view-section {
    animation: viewFadeIn 0.22s var(--ease-smooth) both;
}

@keyframes viewFadeIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.guide-inner-content {
    animation: contentSlideIn 0.18s var(--ease-smooth) both;
}

@keyframes contentSlideIn {
    from {
        opacity: 0;
        transform: translateX(8px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.pc-grid .pc-card:nth-child(1) {
    animation-delay: 0.03s;
}

.pc-grid .pc-card:nth-child(2) {
    animation-delay: 0.06s;
}

.pc-grid .pc-card:nth-child(3) {
    animation-delay: 0.09s;
}

.pc-grid .pc-card:nth-child(4) {
    animation-delay: 0.12s;
}

.pc-grid .pc-card:nth-child(5) {
    animation-delay: 0.15s;
}

.pc-grid .pc-card:nth-child(6) {
    animation-delay: 0.18s;
}

.pc-card {
    border-radius: 14px;
    transition: transform 0.2s var(--ease-spring), box-shadow 0.2s var(--ease-smooth), border-color 0.15s;
}

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

.modal-overlay {
    backdrop-filter: blur(8px) saturate(1.2);
    background: rgba(15, 14, 12, 0.45);
}

.modal-content {
    border-radius: 20px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.20), 0 4px 16px rgba(0, 0, 0, 0.10);
}

.btn-scratchpad {
    background: var(--primary-light);
    color: var(--primary);
    border: 1px solid rgba(217, 119, 87, 0.2);
}

.btn-scratchpad:hover {
    background: rgba(217, 119, 87, 0.18);
    box-shadow: 0 2px 8px var(--primary-glow);
    transform: translateY(-1px);
}

.lang-dropdown {
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12), 0 1px 4px rgba(0, 0, 0, 0.06);
}

.lang-option {
    font-size: 13.5px;
    padding: 10px 16px;
}

.lang-option.active {
    background: var(--primary-light);
    color: var(--primary);
}

.about-creator-card {
    border-radius: 20px;
    box-shadow: var(--shadow-card);
}

.about-pillar {
    border-radius: 14px;
    transition: transform 0.2s var(--ease-spring), box-shadow 0.2s;
}

.about-pillar:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-elevated);
}

.search-input:focus {
    box-shadow: var(--shadow-glow);
}

.pc-search-wrap input:focus {
    box-shadow: var(--shadow-glow);
}

.sidebar-tip-box {
    background: var(--primary-light);
    border: 1px solid rgba(217, 119, 87, 0.15);
    border-left: 3px solid var(--primary);
    border-radius: var(--radius-md);
}

[data-theme="dark"] .sidebar-tip-box {
    background: rgba(217, 119, 87, 0.07);
    border-color: rgba(217, 119, 87, 0.2);
}

[data-theme="dark"] .nav-tab.active {
    box-shadow: 0 2px 16px rgba(217, 119, 87, 0.3);
}

[data-theme="dark"] .guide-content-area {
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .lang-dropdown {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

@media (max-width: 768px) {
    .guide-content-area {
        padding: 24px 20px;
    }

    .guide-inner-content h2 {
        font-size: 20px;
    }

    .hero-heading {
        font-size: 36px;
        letter-spacing: -0.5px;
    }

    .guide-tab-item {
        flex-shrink: 0;
        white-space: nowrap;
    }
}

.sidebar-item-icon {
    flex-shrink: 0;
    opacity: 0.7;
    color: inherit;
    display: flex;
    align-items: center;
    transition: opacity 0.15s, color 0.15s;
}

.sidebar-item.active .sidebar-item-icon {
    opacity: 1;
    color: var(--primary);
}

.sidebar-item-label {
    flex: 1;
    line-height: 1.4;
}

.tools-hero-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 24px 32px;
    margin-bottom: 32px;
    display: flex;
    gap: 20px;
    align-items: center;
    box-shadow: var(--shadow-sm);
}

.tools-hero-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.tools-hero-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 24px;
    font-weight: 400;
    color: var(--text-primary);
    margin-bottom: 6px;
    letter-spacing: -0.3px;
}

.tools-hero-desc {
    font-size: 15px;
    color: var(--text-secondary);
    max-width: 700px;
    line-height: 1.5;
    margin: 0;
}

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 14px;
    padding: 20px;
    transition: transform 0.2s var(--ease-spring), box-shadow 0.2s var(--ease-smooth), border-color 0.15s;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    overflow: hidden;
}

.tool-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-elevated);
    border-color: rgba(217, 119, 87, 0.25);
}

.tool-card-head {
    display: flex;
    justify-content: space-between;
    align-items: start;
}

.tool-card-title {
    font-size: 18px;
    margin: 0;
    color: var(--text-primary);
    font-weight: 600;
}

.tool-card-tags {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}

.tool-tag {
    font-size: 10px;
    background: var(--bg-body);
    padding: 2px 6px;
    border-radius: 4px;
    border: 1px solid var(--border-light);
    color: var(--text-tertiary);
    font-weight: 500;
}

.tool-card-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
    flex: 1;
}

.tool-pricing-badge {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 2px 8px;
    border-radius: 999px;
    border: 1px solid;
    flex-shrink: 0;
}

.tool-pricing-free {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
    border-color: rgba(16, 185, 129, 0.25);
}

.tool-pricing-freemium {
    background: var(--primary-light);
    color: var(--primary);
    border-color: rgba(217, 119, 87, 0.25);
}

.tool-pricing-paid {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    border-color: rgba(239, 68, 68, 0.25);
}

.pc-search-wrap {
    position: relative;
    padding: 24px 32px 20px;
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-app);
}

.pc-search-icon {
    position: absolute;
    left: 48px;
    top: calc(50% - 2px);
    transform: translateY(-50%);
    color: var(--text-tertiary);
    pointer-events: none;
}

.pc-search-input {
    width: 100%;
    padding: 14px 20px 14px 44px;
    font-size: 15px;
    font-family: inherit;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-hover);
    background: var(--bg-card);
    color: var(--text-primary);
    transition: all 0.2s var(--ease-smooth);
    box-shadow: var(--shadow-sm);
}

.pc-search-input:focus {
    border-color: var(--primary);
    box-shadow: 0 4px 16px rgba(217, 119, 87, 0.15);
    outline: none;
}

.pc-search-input::placeholder {
    color: var(--text-tertiary);
    font-weight: 400;
}

.pc-empty {
    padding: 48px 24px;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 15px;
    font-weight: 500;
    grid-column: 1 / -1;
}

.sidebar-hidden .app-footer {
    padding-left: 24px;
    padding-right: 24px;
}

@media (max-width: 768px) {
    .resources-grid {
        grid-template-columns: 1fr !important;
    }

    .tools-hero-card {
        padding: 16px 20px;
    }

    .tool-card-head {
        flex-direction: column;
        gap: 8px;
    }

    .pc-search-wrap {
        padding: 16px 20px 12px;
    }

    .pc-search-icon {
        left: 36px;
    }
}

@media print {
    @page {
        size: A4;
        margin: 0;
        
    }

    body {
        margin: 0;
        padding: 0;
        background: white !important;
    }

    body>*:not(#print-container):not(script):not(style) {
        display: none !important;
    }

    #print-container {
        display: block !important;
        position: static !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        
        background: white !important;
        color: #111827 !important;
    }

    .print-master-table {
        width: 100%;
        border-collapse: collapse;
        table-layout: fixed;
    }

    .print-header-space {
        height: 20mm;
        display: block;
        content: " ";
        
    }

    .print-footer-space {
        height: 20mm;
        display: block;
        content: " ";
        
    }

    .print-page-content {
        padding: 0 20mm;
        box-sizing: border-box;
    }

    .print-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding-bottom: 24px;
        border-bottom: 2px solid #ea580c;
        margin-bottom: 40px;
    }

    .print-header-text {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .print-header-text strong {
        font-size: 26px;
        font-weight: 800;
        color: #111827;
        letter-spacing: -0.04em;
    }

    .print-header-text span {
        font-size: 14px;
        color: #6b7280;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.05em;
    }

    .print-module {
        margin-bottom: 50px;
        page-break-before: auto;
    }

    .print-module-title {
        font-family: 'Inter', system-ui, sans-serif;
        font-size: 28px;
        font-weight: 800;
        color: #111827;
        margin-bottom: 30px;
        letter-spacing: -0.02em;
        line-height: 1.2;
    }

    .print-item {
        margin-bottom: 35px;
        page-break-inside: avoid;
    }

    .print-item-title {
        font-size: 20px;
        font-weight: 700;
        color: #ea580c;
        margin-bottom: 12px;
        border-left: 5px solid #ea580c;
        padding-left: 15px;
    }

    .print-item-content {
        font-size: 13pt;
        line-height: 1.6;
        color: #1f2937;
        padding-left: 20px;
    }

    .print-item-content p {
        margin-bottom: 15px;
    }

    .print-item-content .info-box,
    .print-item-content .concept-analogy,
    .print-item-content .cptc-box {
        background-color: #fff7ed !important;
        border: 1px solid #fdba74 !important;
        border-left: 5px solid #ea580c !important;
        padding: 20px !important;
        border-radius: 8px !important;
        margin: 24px 0 !important;
        color: #111827 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .print-item-content .timeline-grid {
        display: block !important;
    }

    .print-item-content .timeline-item {
        margin-bottom: 20px !important;
        border-left: 2px solid #ea580c !important;
        padding-left: 16px !important;
    }

    .print-footer {
        margin-top: 60px;
        padding-top: 15px;
        border-top: 1px solid #e5e7eb;
        font-size: 10px;
        color: #9ca3af;
        display: flex;
        justify-content: space-between;
        font-weight: 600;
    }

    svg {
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }

    a[href]:after {
        content: none !important;
    }
}

@media (min-width: 769px) {
    .app-layout.sidebar-hidden {
        grid-template-columns: 260px 1fr;
    }

    .app-layout.sidebar-hidden .app-sidebar {
        display: flex !important;
    }

    .app-layout.sidebar-hidden .app-main {
        grid-column: 2;
        padding: 0;
    }
}

.prompts-page {
    padding: 32px 40px;
    max-width: 1100px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .prompts-page {
        padding: 12px 12px 80px;
    }
}

.pa-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 14px;
}

@media (max-width: 900px) {
    .pa-grid {
        grid-template-columns: 1fr;
    }
}

.sidebar-sub-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 12.5px;
    cursor: pointer;
    transition: background 0.13s, color 0.13s;
    min-height: 30px;
    gap: 8px;
}

.sidebar-sub-link:hover {
    background: var(--primary-glow);
    color: var(--primary);
}

.sidebar-sub-count {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-tertiary);
    background: var(--bg-app);
    border: 1px solid var(--border-light);
    padding: 1px 6px;
    border-radius: 8px;
    flex-shrink: 0;
}

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: transform 0.2s var(--ease-spring), box-shadow 0.2s var(--ease-smooth), border-color 0.15s;
}

.tool-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-elevated);
    border-color: rgba(217, 119, 87, 0.2);
}

[data-theme="dark"] .tool-card:hover {
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
}

.tool-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.tool-card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.tool-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.tool-tag {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-tertiary);
    background: var(--bg-body);
    border: 1px solid var(--border-light);
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.tool-card-desc {
    font-size: 13.5px;
    color: var(--text-secondary);
    line-height: 1.6;
    flex: 1;
    margin: 0;
}

.tool-card-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: auto;
    padding: 9px 16px;
    background: var(--primary);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    transition: opacity 0.15s, transform 0.15s;
}

.tool-card-link:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

.tools-hero-card {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-light);
}

.tools-hero-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.tools-hero-title {
    font-family: 'Georgia', 'Charter', serif;
    font-size: 22px;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: -0.3px;
    margin: 0 0 4px;
}

.tools-hero-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

@media (max-width: 900px) {
    .resources-grid {
        grid-template-columns: 1fr !important;
    }
}

.prompts-cat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.prompts-cat-btn {
    padding: 14px 16px;
    border: 1.5px solid var(--border-light);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: border-color 0.18s, background 0.18s, box-shadow 0.18s;
    text-align: left;
    font-family: inherit;
}

.prompts-cat-btn:hover:not(.active) {
    border-color: var(--border-hover);
    background: var(--bg-body);
}

.prompts-cat-btn.active {
    border: 2px solid var(--primary);
    background: var(--primary-light);
    box-shadow: 0 2px 8px var(--primary-glow);
}

.prompts-cat-btn-head {
    display: flex;
    align-items: center;
    gap: 10px;
}

.prompts-cat-btn-head svg {
    flex-shrink: 0;
    color: var(--text-secondary);
    transition: color 0.15s;
}

.prompts-cat-btn.active .prompts-cat-btn-head svg {
    color: var(--primary);
}

.prompts-cat-btn-label {
    flex: 1;
    font-weight: 700;
    font-size: 15px;
    color: var(--text-secondary);
    transition: color 0.15s;
    line-height: 1.2;
}

.prompts-cat-btn.active .prompts-cat-btn-label {
    color: var(--primary);
}

.prompts-cat-btn-count {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-tertiary);
    background: var(--bg-body);
    border: 1px solid var(--border-light);
    padding: 2px 7px;
    border-radius: 10px;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.prompts-cat-btn.active .prompts-cat-btn-count {
    background: rgba(217, 119, 87, 0.15);
    border-color: rgba(217, 119, 87, 0.25);
    color: var(--primary);
}

.prompts-sub-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-light);
}

@media (max-width: 768px) {
    .prompts-sub-row {
        flex-wrap: wrap;
        overflow-x: visible;
        padding-bottom: 8px;
        margin-bottom: 12px;
        gap: 6px;
    }
}

.prompts-sub-pill {
    padding: 7px 16px;
    border-radius: 999px;
    border: 1.5px solid var(--border-light);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    font-family: inherit;
    min-height: 34px;
}

.prompts-sub-pill:hover:not(.active) {
    border-color: var(--border-hover);
    color: var(--text-primary);
    background: var(--bg-body);
}

.prompts-sub-pill.active {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
}

.sidebar-sub-link.active {
    color: var(--primary);
    background: var(--primary-glow);
}

.sidebar-sub-link.active .sidebar-sub-count {
    background: var(--primary-light);
    border-color: rgba(217, 119, 87, 0.25);
    color: var(--primary);
}

@media (max-width: 768px) {

    .app-main {
        padding-bottom: 80px !important;
    }

    .prompts-page {
        padding: 20px 16px 80px;
    }

    .app-sidebar {
        padding: 20px 12px;
        overflow-y: auto;
    }

    .page-hero-card {
        padding: 12px 16px;
        gap: 12px;
        margin-bottom: 16px;
    }

    .page-hero-card-icon {
        width: 36px;
        height: 36px;
        border-radius: 10px;
        flex-shrink: 0;
    }

    .page-hero-card-icon svg {
        width: 18px;
        height: 18px;
    }

    .page-hero-title {
        font-size: 18px;
        margin-bottom: 0;
    }

    .page-hero-sub {
        display: none;
    }

    .prompts-cat-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 8px;
        margin-bottom: 14px;
        padding-bottom: 2px;
    }

    .prompts-cat-grid::-webkit-scrollbar {
        display: none;
    }

    .prompts-cat-btn {
        flex-shrink: 0;
        padding: 7px 14px;
        border-radius: 999px;
        min-width: auto;
        width: auto;
    }

    .prompts-cat-btn-head svg {
        display: none;
    }

    .prompts-cat-btn-label {
        font-size: 13px;
    }

    .main-nav {
        padding: 6px 4px env(safe-area-inset-bottom, 0px);
        box-shadow: 0 -1px 0 var(--border-light), 0 -4px 12px rgba(0, 0, 0, 0.06);
    }

    .nav-tab {
        font-size: 10px;
        padding: 4px 2px;
        min-width: 52px;
        flex-direction: column;
        gap: 3px;
        min-height: 44px;
        border-radius: var(--radius-sm);
    }

    .nav-tab svg {
        width: 22px !important;
        height: 22px !important;
        margin: 0 !important;
    }

    .nav-tab.active {
        color: var(--primary);
        background: var(--primary-light);
        box-shadow: none;
    }

    .pa-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .pcm-card {
        padding: 14px 16px;
    }

    .pcm-header {
        margin-bottom: 10px;
    }

    .pcm-title {
        font-size: 14px;
        margin-bottom: 8px;
    }

    .pcm-snippet {
        font-size: 13px;
        -webkit-line-clamp: 3;
    }

    .prompts-search-wrap {
        max-width: 100% !important;
        margin-bottom: 12px !important;
    }

    .pc-search-input {
        font-size: 14px;
        padding: 11px 16px 11px 38px;
    }

    .prompts-sub-pill {
        padding: 5px 12px;
        font-size: 12px;
    }

    .resources-container {
        padding: 20px 16px !important;
    }

    #view-tools>div {
        padding: 24px 16px !important;
    }

    .hero-heading {
        font-size: 36px !important;
    }

    #sidebar-overlay.open {
        background: rgba(0, 0, 0, 0.45);
    }
}

@media (max-width: 380px) {
    .nav-tab span {
        display: none;
    }

    .nav-tab {
        min-width: 44px;
    }
}

#offline-indicator {
    display: none;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #fee2e2;
    color: #dc2626;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

#offline-indicator::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #dc2626;
    flex-shrink: 0;
}

#offline-indicator.visible {
    display: flex;
}

[data-theme="dark"] #offline-indicator {
    background: rgba(220, 38, 38, 0.15);
    color: #f87171;
}

[data-theme="dark"] #offline-indicator::before {
    background: #f87171;
}

#pwa-install-btn {
    display: none;
}

#pwa-install-btn.visible {
    display: flex;
}

#sw-update-banner {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-left: 3px solid var(--primary);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
    font-size: 13px;
    color: var(--text-primary);
    white-space: nowrap;
    animation: banner-slide-up 0.25s ease;
}

@keyframes banner-slide-up {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

#sw-update-banner button {
    padding: 5px 14px;
    border-radius: var(--radius-sm);
    border: none;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    min-height: unset;
    font-family: inherit;
    background: var(--primary);
    color: #fff;
    transition: opacity 0.15s;
}

#sw-update-banner button:hover {
    opacity: 0.85;
}

#sw-update-banner .sw-banner-close {
    background: transparent;
    color: var(--text-tertiary);
    padding: 4px;
    display: flex;
    align-items: center;
}

#sw-update-banner .sw-banner-close:hover {
    color: var(--text-primary);
    background: var(--bg-body);
}

@media (max-width: 768px) {
    #sw-update-banner {
        bottom: 90px;
        left: 16px;
        right: 16px;
        transform: none;
        white-space: normal;
        animation: banner-slide-up-mobile 0.25s ease;
    }

    @keyframes banner-slide-up-mobile {
        from {
            opacity: 0;
            transform: translateY(12px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}