:root {
    --bg-body: #0b1020;
    --bg-card: #111a2e;
    --copy-primary: #e2e8f0;
    --copy-muted: #94a3b8;
    --accent-color: #3b82f6;
    --accent-hover: #2563eb;
    --accent-light: rgba(59, 130, 246, 0.16);
    --accent-glow: rgba(59, 130, 246, 0.08);
    --accent-gradient: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
    --accent-gradient-hover: linear-gradient(135deg, #2563eb 0%, #0891b2 100%);
    --accent-shadow-color: rgba(59, 130, 246, 0.2);
    --border-light: #1f2a44;
    --border-strong: #2b3a5f;
    --hover-bg: #0f1930;
    --color-danger: #f87171;
    --color-danger-bg: rgba(248, 113, 113, 0.16);
    --color-success: #34d399;
    --color-success-bg: rgba(52, 211, 153, 0.16);
    --color-warning: #fbbf24;
    --color-warning-bg: rgba(251, 191, 36, 0.16);
    --color-gold: #f59e0b;
    --color-silver: #94a3b8;
    --color-bronze: #c2855a;
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --container-max: 1100px;
    --header-height: 72px;
    --shadow-subtle: 0 16px 40px -16px rgba(0, 0, 0, 0.75), 0 6px 18px -8px rgba(0, 0, 0, 0.55);
    --shadow-focus: 0 0 0 4px var(--accent-light);
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --font-size-h1: clamp(1.8rem, 4vw, 2.8rem);
    --font-size-h2: clamp(1.35rem, 3.5vw, 1.8rem);
    --font-size-h3: clamp(1.1rem, 2.5vw, 1.35rem);
    --font-size-body: clamp(0.95rem, 0.5vw + 0.8rem, 1.05rem);
    --font-size-sm: clamp(0.8rem, 0.3vw + 0.75rem, 0.9rem);
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --pill-active-bg: var(--accent-gradient);
    --pill-active-border: transparent;
    --pill-active-copy: #ffffff;
    --sidebar-mobile-bg: rgba(11, 16, 32, 0.92);
    --skeleton-shimmer: rgba(255, 255, 255, 0.1);
}

body.theme-blue {
    --accent-color: #3b82f6;
    --accent-hover: #2563eb;
    --accent-light: rgba(59, 130, 246, 0.16);
    --accent-glow: rgba(59, 130, 246, 0.08);
    --accent-gradient: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
    --accent-gradient-hover: linear-gradient(135deg, #2563eb 0%, #0891b2 100%);
    --accent-shadow-color: rgba(59, 130, 246, 0.2);
}

body.theme-purple {
    --accent-color: #8b5cf6;
    --accent-hover: #7c3aed;
    --accent-light: rgba(139, 92, 246, 0.16);
    --accent-glow: rgba(139, 92, 246, 0.08);
    --accent-gradient: linear-gradient(135deg, #8b5cf6 0%, #d946ef 100%);
    --accent-gradient-hover: linear-gradient(135deg, #7c3aed 0%, #c026d3 100%);
    --accent-shadow-color: rgba(139, 92, 246, 0.2);
}

body.theme-green {
    --accent-color: #10b981;
    --accent-hover: #059669;
    --accent-light: rgba(16, 185, 129, 0.16);
    --accent-glow: rgba(16, 185, 129, 0.08);
    --accent-gradient: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
    --accent-gradient-hover: linear-gradient(135deg, #059669 0%, #0d9488 100%);
    --accent-shadow-color: rgba(16, 185, 129, 0.2);
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    background-color: var(--bg-body);
    color-scheme: dark;
}

body {
    font-family: var(--font-sans);
    font-size: var(--font-size-body);
    line-height: 1.6;
    color: var(--copy-primary);
    background-color: var(--bg-body);
    background-image: none;
    -webkit-font-smoothing: antialiased;
    display: grid;
    grid-template-columns: 80px 1fr;
    grid-template-rows: var(--header-height) 1fr auto;
    grid-template-areas:
        "header header"
        "sidebar main"
        "sidebar footer";
    min-height: 100vh;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    border-left: 1px solid var(--border-light);
    border-right: 1px solid var(--border-light);
    box-shadow: 0 0 32px rgba(0, 0, 0, 0.45);
}

h1 {
    font-size: var(--font-size-h1);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.15;
    color: var(--copy-primary);
}

h2,
.error-heading {
    font-size: var(--font-size-h2);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
}

h3 {
    font-size: var(--font-size-h3);
    font-weight: 650;
    letter-spacing: -0.01em;
    line-height: 1.4;
}

h4 {
    font-size: calc(var(--font-size-sm) * 1.1);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

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

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

.text-truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.copy-primary {
    color: var(--copy-primary);
}

.copy-muted {
    color: var(--copy-muted);
    font-size: var(--font-size-sm);
}

.copy-danger {
    color: var(--color-danger);
}

.copy-accent {
    color: var(--accent-color);
}

.copy-small {
    font-size: var(--font-size-sm);
}

.copy-tiny {
    font-size: calc(var(--font-size-sm) * 0.9);
}

.copy-large {
    font-size: calc(var(--font-size-body) * 1.1);
}

.copy-relaxed {
    line-height: 1.7;
}

.type-strong {
    font-weight: 700;
}

.type-semibold {
    font-weight: 600;
}

.capitalize {
    text-transform: capitalize;
}

.prose-spaced {
    line-height: 1.7;
    font-size: 16px;
}

.gradient-title {
    background: linear-gradient(135deg, var(--copy-primary) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.block {
    display: block;
}

.hidden,
[hidden] {
    display: none !important;
}

.overflow-clipped {
    overflow: hidden;
}

.opacity-soft {
    opacity: 0.8;
}

.opacity-muted {
    opacity: 0.65;
}

.interaction-disabled {
    pointer-events: none;
}

.pointer-enabled {
    cursor: pointer;
}

.pointer-default {
    cursor: default;
}

.center-inline {
    margin-left: auto;
    margin-right: auto;
}

.full-width {
    width: 100%;
}

.half-width {
    width: 50%;
}

.three-quarter-width {
    width: 75%;
}

.width-chip-small {
    width: 64px;
}

.width-chip-large {
    width: 96px;
}

.height-chip {
    height: 32px;
}

.container {
    width: 100%;
    padding: 0 clamp(16px, 3vw, 24px);
}

.spacing-top-tiny {
    margin-top: 4px;
}

.spacing-top-small {
    margin-top: 8px;
}

.spacing-top-regular {
    margin-top: 12px;
}

.spacing-top-medium {
    margin-top: 16px;
}

.spacing-top-large {
    margin-top: 24px;
}

.spacing-top-xlarge {
    margin-top: 32px;
}

.spacing-bottom-small {
    margin-bottom: 8px;
}

.spacing-bottom-regular {
    margin-bottom: 12px;
}

.spacing-bottom-medium {
    margin-bottom: 16px;
}

.spacing-bottom-large {
    margin-bottom: 24px;
}

.spacing-inline-small {
    margin-left: 8px;
}

.spacing-inline-medium {
    margin-left: 16px;
}

.padding-top-small {
    padding-top: 8px;
}

.padding-top-medium {
    padding-top: 16px;
}

.padding-top-large {
    padding-top: 24px;
}

.padding-none {
    padding: 0;
}

.padding-compact {
    padding: 20px;
}

.padding-spacious {
    padding: 32px;
}

.padding-inline-small {
    padding-left: 8px;
    padding-right: 8px;
}

.padding-inline-medium {
    padding-left: 16px;
    padding-right: 16px;
}

.padding-block-small {
    padding-top: 4px;
    padding-bottom: 4px;
}

.border-radius-pill {
    border-radius: 9999px;
}

.layout-flex {
    display: flex;
}

.layout-stack {
    flex-direction: column;
}

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

.justify-center {
    justify-content: center;
}

.justify-space-between {
    justify-content: space-between;
}

.layout-justify-between {
    justify-content: space-between;
}

.bg-primary {
    background: var(--accent-gradient) !important;
}

.bg-danger {
    background-color: var(--color-danger) !important;
}

.layout-flex-fill {
    flex: 1;
}

.layout-gap-compact {
    gap: 8px;
}

.layout-gap-regular {
    gap: 16px;
}

.layout-gap-loose {
    gap: 24px;
}

.layout-gap-wide {
    gap: 48px;
}

.border-t {
    border-top: 1px solid var(--border-light);
}

.border-light {
    border-color: var(--border-light);
}

.bullet-list {
    list-style-type: disc;
    padding-left: 20px;
}

.bullet-list-compact>*+* {
    margin-top: 8px;
}

.bullet-list-comfortable>*+* {
    margin-top: 12px;
}

.editor-height-medium {
    min-height: 80px;
}

.editor-height-large {
    min-height: 120px;
}

#app {
    grid-area: main;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.main-content-shell {
    flex: 1;
    padding: 16px clamp(16px, 3vw, 32px);
    width: 100%;
}

.page-shell {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.section-heading {
    margin-bottom: 16px;
}

#site-header {
    grid-area: header;
    position: sticky;
    top: 0;
    height: var(--header-height);
    background: var(--bg-body);
    display: flex;
    align-items: center;
    z-index: 120;
}

.header-logo-box {
    width: 80px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid var(--border-light);
    flex-shrink: 0;
}

.header-action-box {
    flex: 1;
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 clamp(16px, 4vw, 48px);
    overflow: hidden;
}

.header-title-text {
    font-size: var(--font-size-h2);
    font-weight: 700;
    color: var(--copy-primary);
    margin: 0;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.logo-img {
    width: 42px;
    height: auto;
    object-fit: contain;
    transition: var(--transition);
}

.logo-img:hover {
    transform: scale(1.05);
}

.sidebar-container {
    grid-area: sidebar;
    position: sticky;
    top: var(--header-height);
    width: 100%;
    height: calc(100vh - var(--header-height));
    padding: 32px 0;
    background: var(--bg-body);
    border-right: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 110;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
}

.nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    color: var(--copy-muted);
    transition: var(--transition);
}

.nav-item.active,
.nav-item:hover {
    background: var(--accent-light);
    color: var(--accent-color);
}

.nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

#site-footer {
    grid-area: footer;
    padding: clamp(16px, 3vw, 28px) clamp(16px, 4vw, 40px);
}

.site-footer-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding-top: 40px;
    border-top: 1px solid var(--border-light);
    color: var(--copy-muted);
    font-size: var(--font-size-sm);
}

.site-site-footer-bar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}

.site-footer-bar a:hover {
    color: var(--accent-color);
}

.footer-copyright-text {
    margin-top: 0;
    margin-left: auto;
    text-align: right;
}

.site-search-form {
    position: relative;
    width: 100%;
}

.site-search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    color: var(--copy-muted);
}

.site-search-input {
    width: 100%;
    padding: 12px 20px 12px 56px;
    border-radius: 30px;
    border: 1px solid var(--border-light);
    background: var(--hover-bg);
    font-size: var(--font-size-body);
    color: var(--copy-primary);
    transition: var(--transition);
    outline: none;
}

.site-search-input:focus {
    border-color: var(--accent-color);
    background: var(--bg-card);
    box-shadow: var(--shadow-focus);
}

.category-filter-button {
    white-space: nowrap;
    padding: 8px 20px;
    border-radius: 30px;
    border: 1px solid var(--border-strong);
    background: var(--bg-card);
    color: var(--copy-primary);
    font-weight: 600;
    font-size: var(--font-size-sm);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.category-filter-button:hover {
    background: var(--hover-bg);
    transform: translateY(-1px);
}

.category-filter-button.active {
    background: var(--pill-active-bg);
    border-color: var(--pill-active-border);
    color: var(--pill-active-copy);
}

.horizontal-scroller-shell {
    width: 100%;
}

.horizontal-scroller-shell-header {
    width: 100%;
}

.horizontal-scroller-viewport {
    min-width: 0;
    overflow: hidden;
}

.horizontal-scroller-track,
.category-filter-track {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding: 8px 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

.horizontal-scroller-track::-webkit-scrollbar,
.category-filter-track::-webkit-scrollbar {
    display: none;
}

.category-filter-track {
    gap: 12px;
    align-items: center;
}

.button-primary,
.button-secondary,
.button-danger,
.button-google,
.button-telegram {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: var(--font-size-sm);
    padding: 12px 24px;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
}

.button-primary {
    background: var(--accent-gradient);
    color: #ffffff;
    box-shadow: 0 4px 12px var(--accent-shadow-color);
}

.button-primary:hover {
    background: var(--accent-gradient-hover);
    transform: translateY(-2px);
}

.button-primary.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.button-secondary {
    background: var(--bg-card);
    color: var(--copy-primary);
    border-color: var(--border-strong);
}

.button-secondary:hover {
    background: var(--hover-bg);
    border-color: var(--copy-muted);
    transform: translateY(-2px);
}

.button-google {
    background: var(--bg-card);
    color: var(--copy-primary);
    border-color: var(--border-strong);
    gap: 12px;
    padding: 14px 24px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-subtle);
}

.button-google:hover {
    background: var(--hover-bg);
    transform: translateY(-1px);
}

.button-telegram {
    background: #0088cc;
    color: #ffffff;
    border-radius: var(--radius-md);
    text-align: center;
}

.button-danger {
    background: var(--color-danger);
    color: #ffffff;
    border: none;
}

.feedback-button {
    background: none;
    border: none;
    color: var(--copy-muted);
    cursor: pointer;
    transition: var(--transition);
}

.feedback-button:hover:not(:disabled) {
    color: var(--accent-color);
    transform: translateY(-2px);
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: clamp(16px, 2.4vw, 24px);
    transition: var(--transition);
}

.tab-navigation {
    display: flex;
    gap: 8px;
    border-bottom: 2px solid var(--border-light);
    margin-bottom: 24px;
}

.tab-button {
    padding: 12px 24px;
    font-weight: 600;
    background: transparent;
    border: none;
    color: var(--copy-muted);
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: var(--font-size-body);
    transition: var(--transition);
}

.tab-button:hover {
    color: var(--accent-color);
}

.tab-button.active {
    color: var(--accent-color);
    border-bottom-color: var(--accent-color);
}

.tab-panel {
    width: 100%;
}

.tab-panel.hidden {
    display: none !important;
}

.register-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--copy-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.form-field-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    border: none;
}

.split-form-field-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

input:not(.site-search-input),
select,
textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    font-family: var(--font-sans);
    font-size: var(--font-size-sm);
    background: var(--bg-card);
    color: var(--copy-primary);
    transition: var(--transition);
    outline: none;
}

input:focus:not(.site-search-input),
select:focus,
textarea:focus {
    border-color: var(--accent-color);
    box-shadow: var(--shadow-focus);
}

input[readonly],
.input-readonly {
    background: var(--hover-bg);
    cursor: not-allowed;
    color: var(--copy-muted);
    border-color: var(--border-light);
}

.textarea-base {
    padding: 14px 16px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    cursor: pointer;
    font-size: var(--font-size-sm);
    color: var(--copy-primary);
    text-align: left;
}

.checkbox-container input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    min-width: 24px;
    border: 2px solid var(--border-strong);
    border-radius: 8px;
    background-color: var(--bg-body);
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
}

.checkbox-container input[type="checkbox"]:checked {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

.checkbox-container input[type="checkbox"]:checked::after {
    content: '';
    width: 6px;
    height: 12px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    position: absolute;
    top: 2px;
}

.checkbox-container input[type="checkbox"]:hover {
    border-color: var(--accent-hover);
}

.panel-title {
    font-size: var(--font-size-h3);
    font-weight: 700;
    margin-bottom: 20px;
    border-left: 4px solid var(--accent-color);
    padding-left: 10px;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 99999;
}

.modal-card {
    width: 100%;
    max-width: 520px;
    max-height: calc(100vh - 40px);
    position: relative;
    margin: auto;
    overflow-y: auto;
    scrollbar-width: thin;
}

.modal-close-btn {
    position: absolute;
    top: 12px;
    right: 16px;
    background: transparent;
    border: none;
    font-size: 1.8rem;
    color: var(--copy-muted);
    cursor: pointer;
    line-height: 1;
    transition: var(--transition);
}

.modal-close-btn:hover {
    color: var(--color-danger);
    transform: scale(1.1);
}

.modal-flex-layout {
    display: flex;
    flex-direction: column;
    overflow: hidden !important;
}

.modal-sticky-header {
    flex-shrink: 0;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.modal-scrollable-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 4px;
    scrollbar-width: thin;
}

.modal-sticky-footer {
    flex-shrink: 0;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
}

#toast-container {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99995;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
    align-items: center;
    width: 100%;
}

.toast-msg {
    background: var(--bg-card);
    color: var(--copy-primary);
    padding: 12px 28px;
    border-radius: 9999px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    font-size: var(--font-size-sm);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
    border: none;
    pointer-events: auto;
    transition: opacity 0.3s ease, transform 0.3s ease;
    animation: toastSlideDown 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

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

.skeleton {
    position: relative;
    overflow: hidden;
    background: var(--hover-bg);
    border-radius: var(--radius-sm);
}

.skeleton::after {
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-150%);
    background: linear-gradient(90deg, transparent, var(--skeleton-shimmer), transparent);
    animation: skeletonShimmer 1s ease-in-out infinite;
}

.skeleton-text {
    height: 16px;
    margin-bottom: 12px;
}

.skeleton-copy-large {
    height: 24px;
    margin-bottom: 16px;
}

.skeleton-card {
    height: 200px;
    border-radius: var(--radius-lg);
}

.loader-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 40vh;
}

.loader-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-light);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes toastSlideDown {
    0% {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes skeletonShimmer {
    100% {
        transform: translateX(150%);
    }
}

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

@media (min-width: 1024px) {
}

@media (min-width: 600px) {
    .form-field-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.header-home-wrapper {
    display: flex;
    align-items: center;
    width: 100%;
    justify-content: space-between;
    gap: 16px;
}

.header-categories-container {
    flex: 1;
    min-width: 0;
}

.header-search-container {
    width: 280px;
    flex-shrink: 0;
}

.header-detail-title-wrapper {
    display: flex;
    align-items: center;
    height: 100%;
}

.header-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: var(--font-size-h2);
    font-weight: 700;
    color: var(--copy-primary);
    transition: var(--transition);
}

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

.header-back-icon {
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    body {
        display: flex;
        flex-direction: column;
    }

    #site-header {
        position: sticky;
        top: 0;
        width: 100%;
        border-bottom: 1px solid var(--border-light);
    }

    .header-logo-box {
        width: 64px;
    }

    .header-action-box {
        padding: 0 16px;
    }

    .header-title-text {
        font-size: calc(var(--font-size-h3) * 1.1);
    }

    .logo-img {
        width: 36px;
    }

    .sidebar-container {
        position: fixed;
        bottom: 16px;
        left: 16px;
        right: 16px;
        top: auto;
        width: calc(100% - 32px);
        height: 64px;
        padding: 0;
        background: var(--sidebar-mobile-bg);
        backdrop-filter: blur(8px);
        border: 1px solid var(--border-light);
        border-radius: 20px;
        box-shadow: var(--shadow-subtle);
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        z-index: 9999;
    }

    .sidebar-nav {
        flex-direction: row;
        justify-content: center;
        gap: 16px;
        width: auto;
    }

    .nav-item {
        width: 44px;
        height: 44px;
    }

    .main-content-shell {
        padding: 16px clamp(16px, 3vw, 20px) 24px clamp(16px, 3vw, 20px);
    }

    body.has-categories .main-content-shell {
        padding-top: 110px;
    }

    #site-footer {
        padding: 20px;
        padding-bottom: 100px;
    }

    .site-footer-bar {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .site-site-footer-bar {
        justify-content: center;
    }

    .footer-copyright-text {
        margin-left: 0;
        text-align: center;
    }

    .split-form-field-grid {
        grid-template-columns: 1fr;
    }

    #site-header {
        height: auto !important;
        min-height: var(--header-height);
        flex-wrap: wrap;
        display: flex;
        align-items: flex-start;
        padding: 0 16px;
    }

    .header-logo-box {
        height: var(--header-height);
        display: flex;
        align-items: center;
        width: 64px;
        border-right: none !important;
        position: relative;
        z-index: 10;
        background: var(--bg-body);
    }

    .header-action-box {
        flex: 1;
        width: calc(100% - 64px);
        min-width: 0;
        display: flex;
        flex-direction: column;
        padding: 0 !important;
        overflow: visible !important;
    }

    .header-home-wrapper {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 0 !important;
    }

    .header-search-container {
        order: 1;
        width: 100%;
        height: var(--header-height);
        display: flex;
        justify-content: flex-end;
        align-items: center;
        position: relative;
        z-index: 10;
        background: var(--bg-body);
    }

    .header-categories-container {
        position: absolute;
        top: var(--header-height);
        left: 0;
        right: 0;
        width: auto;
        padding: 8px 16px 16px 16px;
        border-top: 1px solid var(--border-light);
        border-bottom: 1px solid var(--border-light);
        background: var(--bg-body);
        z-index: 1;
    }

    .site-search-input {
        padding: 10px 16px 10px 44px !important;
        font-size: var(--font-size-sm) !important;
    }

    .site-search-icon {
        left: 14px !important;
    }

    .header-detail-title-wrapper {
        width: 100%;
        height: var(--header-height);
        display: flex;
        align-items: center;
        justify-content: flex-start;
        padding-left: 12px;
    }

    .header-title-text {
        width: 100%;
        text-align: left;
        font-size: calc(var(--font-size-h3) * 1.1);
        margin: 0 0 0 12px;
        line-height: var(--header-height);
    }
}

@media (max-width: 768px) {
    .header-categories-container {
        transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.25s ease;
        will-change: transform, opacity;
        transform: translateY(0);
        opacity: 1;
        overflow: hidden;
    }

    #site-header.header-categories-hidden .header-categories-container {
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
    }
}

.upgrade-modal-title {
    font-size: var(--font-size-h2);
    font-weight: 800;
    letter-spacing: -0.02em;
}

.upgrade-feature-table {
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.upgrade-table-header {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    padding: 10px 16px;
    background: var(--hover-bg);
    border-bottom: 1px solid var(--border-light);
}

.upgrade-table-row {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-light);
    transition: var(--transition);
    align-items: center;
}

.upgrade-table-row:last-child {
    border-bottom: none;
}

.upgrade-table-row:hover {
    background: var(--hover-bg);
}

.upgrade-table-col-feature {
    font-size: var(--font-size-sm);
    color: var(--copy-primary);
}

.upgrade-table-col-plan {
    min-width: 80px;
    text-align: center;
    font-size: var(--font-size-sm);
    font-weight: 700;
    white-space: nowrap;
}

.upgrade-table-header .upgrade-table-col-feature {
    font-size: calc(var(--font-size-sm) * 0.85);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--copy-muted);
}

.upgrade-table-header .upgrade-table-col-plan {
    font-size: calc(var(--font-size-sm) * 0.85);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--copy-muted);
}

.upgrade-col-pro {
    color: var(--color-gold);
}

.upgrade-col-free {
    color: var(--copy-muted);
}

.upgrade-plan-option {
    display: block;
    cursor: pointer;
}

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

.upgrade-plan-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 2px solid var(--border-strong);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    transition: var(--transition);
    cursor: pointer;
}

.upgrade-plan-option input[type="radio"]:checked+.upgrade-plan-card {
    border-color: var(--accent-color);
    background: var(--accent-light);
    box-shadow: 0 0 0 1px var(--accent-color);
}

.upgrade-plan-card:hover {
    border-color: var(--border-strong);
    background: var(--hover-bg);
}

.upgrade-plan-option input[type="radio"]:checked+.upgrade-plan-card:hover {
    border-color: var(--accent-color);
    background: var(--accent-light);
}

.upgrade-plan-label {
    font-weight: 700;
    font-size: var(--font-size-sm);
    color: var(--copy-primary);
    flex: 1;
}

.upgrade-plan-price {
    font-weight: 800;
    font-size: var(--font-size-sm);
    color: var(--accent-color);
    white-space: nowrap;
}

.upgrade-plan-note {
    display: block;
    font-size: calc(var(--font-size-sm) * 0.85);
    color: var(--copy-muted);
    white-space: nowrap;
}

.upgrade-pricing-section {
    text-align: left;
}
