/* ═══════════════════════════════════════════════════════════════════════════
   ProdFoto — Design System «Цифровой сад»
   ═══════════════════════════════════════════════════════════════════════════ */

:root {
    /* Landing page palette */
    --bg-rgb: 247, 246, 251;
    /* #f7f6fb */
    --surface-rgb: 255, 255, 255;
    /* #ffffff */
    --border-rgb: 229, 227, 236;
    /* #e5e3ec */
    --text-primary-rgb: 26, 26, 26;
    /* #1a1a1a */
    --text-muted-rgb: 107, 107, 107;
    /* #6b6b6b */
    --accent-rgb: 123, 79, 243;
    /* #7b4ff3 */
    --accent-hover-rgb: 98, 70, 234;
    /* #6246ea */
    --accent-light-rgb: 241, 235, 254;
    /* #f1ebfe */

    --bg: rgb(var(--bg-rgb));
    --surface: rgb(var(--surface-rgb));
    --border: rgb(var(--border-rgb));
    --text-primary: rgb(var(--text-primary-rgb));
    --text-muted: rgb(var(--text-muted-rgb));
    --text-light: #9ca3af;
    --accent: rgb(var(--accent-rgb));
    --accent-hover: rgb(var(--accent-hover-rgb));
    --accent-light: rgb(var(--accent-light-rgb));
    --bg-hover: rgba(var(--accent-rgb), 0.06);

    --success: rgb(var(--accent-rgb));
    --danger: #ef4444;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;

    /* Smoother transitions */
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ── Reset & Global ─────────────────────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg);
    background-image:
        radial-gradient(circle at top left, rgba(var(--accent-rgb), 0.12), transparent 28%),
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.10), transparent 24%),
        linear-gradient(180deg, rgba(var(--surface-rgb), 0.96), rgba(var(--bg-rgb), 1));
    color: var(--text-primary);
    line-height: 1.5;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-top: 64px;
    /* Space for fixed navbar */
    position: relative;
    overflow-x: hidden;
}

/* Background animated blobs for a modern "impressive" look */
.bg-blobs {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    opacity: 0.4;
    border-radius: 50%;
    animation: float 20s infinite ease-in-out alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(var(--accent-rgb), 0.28) 0%, rgba(var(--accent-rgb), 0) 70%);
}

.blob-2 {
    bottom: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.18) 0%, rgba(59, 130, 246, 0) 70%);
    animation-delay: -5s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(100px, 50px) scale(1.1);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

.fade-in-up {
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

a:hover {
    color: var(--accent-hover);
}

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

/* ── Typography ─────────────────────────────────────────────────────────── */
h1 {
    font-size: 48px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

h2 {
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

h3 {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.4;
}

h4 {
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
}

.text-sm {
    font-size: 13px;
    color: var(--text-muted);
}

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

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

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

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

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

.font-bold {
    font-weight: 700;
}

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

/* ── Layout ──────────────────────────────────────────────────────────────── */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-lg {
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 80px 0;
}

.section-sm {
    padding: 48px 0;
}

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

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

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

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

.gap-1 {
    gap: 8px;
}

.gap-2 {
    gap: 16px;
}

.gap-3 {
    gap: 24px;
}

.gap-4 {
    gap: 32px;
}

.grid {
    display: grid;
}

.grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

.w-full {
    width: 100%;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.mt-1 {
    margin-top: 8px;
}

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

.mt-3 {
    margin-top: 24px;
}

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

.mb-1 {
    margin-bottom: 8px;
}

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

.mb-3 {
    margin-bottom: 24px;
}

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

.p-2 {
    padding: 16px;
}

.p-3 {
    padding: 24px;
}

.p-4 {
    padding: 32px;
}

.hidden {
    display: none;
}

.relative {
    position: relative;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 15px;
    border: none;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), background-color var(--transition), box-shadow var(--transition);
    font-family: inherit;
    text-decoration: none;
}

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

.btn:active {
    transform: translateY(1px);
}

.btn-primary {
    background: linear-gradient(135deg, rgb(var(--accent-rgb)) 0%, #a855f7 58%, #ec4899 100%);
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(var(--accent-rgb), 0.28), 0 4px 10px rgba(168, 85, 247, 0.18);
}

.btn-primary:hover {
    background: linear-gradient(135deg, rgb(var(--accent-hover-rgb)) 0%, #9333ea 58%, #db2777 100%);
    box-shadow: 0 16px 34px rgba(var(--accent-rgb), 0.34), 0 6px 16px rgba(219, 39, 119, 0.18);
    color: #ffffff;
}

.btn-secondary {
    background-color: rgba(var(--text-primary-rgb), 0.05);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background-color: rgba(var(--text-primary-rgb), 0.08);
    color: var(--text-primary);
}

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

.btn-outline:hover {
    background: var(--accent-light);
}

.btn-dark {
    background-color: var(--text-primary);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-dark:hover {
    background-color: #000000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #ffffff;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    background: var(--danger-hover);
    color: #fff;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 17px;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ── Cards ───────────────────────────────────────────────────────────────── */
.card {
    background: rgba(var(--surface-rgb), 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(var(--border-rgb), 0.8);
    border-radius: var(--radius-md);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
}

.card-body {
    padding: 24px;
}

.card-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
}

/* ── Inputs ──────────────────────────────────────────────────────────────── */
.form-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    font-family: inherit;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--text-primary);
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(26, 122, 74, 0.1);
}

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

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

.form-group {
    margin-bottom: 20px;
}

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

select.form-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 20px;
    padding-right: 40px;
}

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

/* ── Badge ───────────────────────────────────────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: var(--radius-lg);
    background: var(--accent-light);
    color: var(--accent);
}

.badge-dark {
    background: var(--text-primary);
    color: #fff;
}

.badge-warning {
    background: #FFF3E0;
    color: #E65100;
}

.badge-danger {
    background: #FFEBEE;
    color: var(--danger);
}

/* ── Navbar ──────────────────────────────────────────────────────────────── */
.navbar {
    height: 72px;
    background: rgba(var(--surface-rgb), 0.72);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(var(--border-rgb), 0.75);
    box-shadow: 0 12px 32px rgba(27, 22, 44, 0.05);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: background-color var(--transition);
}

.navbar-inner {
    padding-left: 30px;
    padding-right: 30px;
    margin: 12px 10px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-brand {
    display: inline-flex;
    align-items: center;
}

.navbar-brand:hover {
    color: var(--text-primary);
}

.navbar-brand--logo {
    flex-shrink: 0;
}

.navbar-brand-logo {
    display: block;
    width: auto;
    height: 40px;
}

.navbar-nav {
    display: flex;
    align-items: center;
    gap: 32px;
    list-style: none;
}

.navbar-nav a {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    transition: color var(--transition);
}

.navbar-nav a:hover {
    color: var(--accent);
}

.navbar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.navbar-credits {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--accent);
}

.navbar-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgb(var(--accent-rgb)), #ec4899);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* ── Mobile nav toggle ──────────────────────────────────────────────────── */
.navbar-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.navbar-toggle svg {
    width: 24px;
    height: 24px;
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.footer {
    background:
        radial-gradient(circle at top center, rgba(var(--accent-rgb), 0.07), transparent 28%),
        rgba(var(--surface-rgb), 0.92);
    border-top: 1px solid rgba(var(--border-rgb), 0.75);
    padding: 48px 0 24px;
    margin-top: 80px;
    backdrop-filter: blur(10px);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand {
    margin-bottom: 12px;
}

.footer-brand--logo {
    display: inline-flex;
    align-items: center;
}

.footer-logo-img {
    display: block;
    width: auto;
    height: 42px;
}

.footer-desc {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
}

.footer-heading {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    font-size: 14px;
    color: var(--text-muted);
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-light);
}

/* ── Modal ───────────────────────────────────────────────────────────────── */
/* ── File Upload / Interactive ─────────────────────────────────────────── */
.upload-zone {
    border: 2px dashed rgba(var(--border-rgb), 1);
    border-radius: var(--radius-md);
    padding: 32px 20px;
    text-align: center;
    cursor: pointer;
    background: rgba(var(--surface-rgb), 0.5);
    transition: all var(--transition);
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--accent);
    background: rgba(var(--accent-rgb), 0.05);
    transform: scale(1.02);
}

.hover-accent:hover {
    border-color: var(--accent) !important;
    color: var(--accent) !important;
    transform: translateX(4px);
}

/* ── Modals ────────────────────────────────────────────────────────────── */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal {
    background: var(--surface);
    box-shadow: var(--shadow-lg);
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(20px);
    transition: transform 0.25s;
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-size: 18px;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background var(--transition);
    color: var(--text-muted);
}

.modal-close:hover {
    background: #f0f0f0;
}

.modal-body {
    padding: 24px;
}

/* ── Ticker / Marquee ────────────────────────────────────────────────────── */
.ticker-wrap {
    overflow: hidden;
    background: var(--text-primary);
    padding: 10px 0;
}

.ticker {
    display: flex;
    animation: ticker 30s linear infinite;
    white-space: nowrap;
}

.ticker-item {
    flex-shrink: 0;
    padding: 0 32px;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

@keyframes ticker {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* ── Upload Zone ─────────────────────────────────────────────────────────── */
.upload-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius-md);
    padding: 32px;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition);
    background: #FAFAFA;
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--accent);
    background: var(--accent-light);
}

/* ── Step indicator ──────────────────────────────────────────────────────── */
.step-num {
    font-size: 14px;
    font-weight: 700;
    font-style: italic;
    color: var(--text-light);
}

/* ── Pricing card ────────────────────────────────────────────────────────── */
.pricing-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 28px;
    position: relative;
    transition: all var(--transition);
}

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

.pricing-card.highlighted {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent), var(--shadow-md);
}

.pricing-name {
    font-size: 24px;
    font-weight: 700;
    font-style: italic;
}

.pricing-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}

.pricing-price {
    font-size: 36px;
    font-weight: 700;
    margin: 16px 0 8px;
}

.pricing-price .currency {
    font-size: 24px;
}

.pricing-credits {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    color: var(--accent);
}

.pricing-features {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.pricing-feature {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    margin-bottom: 8px;
}

.pricing-feature .check {
    color: var(--accent);
    font-weight: 700;
}

.pricing-badge {
    position: absolute;
    top: -12px;
    right: 16px;
    background: var(--accent);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: var(--radius-lg);
}

/* ── FAQ Accordion ───────────────────────────────────────────────────────── */
.faq-item {
    background: var(--text-primary);
    color: #fff;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
    overflow: hidden;
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    color: #fff;
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: inherit;
}

.faq-question svg {
    width: 20px;
    height: 20px;
    transition: transform var(--transition);
    flex-shrink: 0;
}

.faq-question[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    font-size: 14px;
    line-height: 1.6;
    color: #ccc;
}

.faq-answer.open {
    max-height: 300px;
    padding: 0 20px 16px;
}

/* ── Comparison Table ────────────────────────────────────────────────────── */
.comparison-table {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.comparison-col {
    padding: 32px;
}

.comparison-col.old {
    background: #f5f5f5;
}

.comparison-col.new {
    background: var(--accent-light);
}

/* ── Dashboard cards ─────────────────────────────────────────────────────── */
.stat-card {
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
}

.stat-card-green {
    background: linear-gradient(135deg, rgb(var(--accent-rgb)) 0%, #a855f7 58%, #ec4899 100%);
    color: #fff;
}

.stat-card-dark {
    background: var(--text-primary);
    color: #fff;
}

.stat-number {
    font-size: 42px;
    font-weight: 700;
    line-height: 1;
}

.stat-label {
    font-size: 13px;
    margin-top: 4px;
    opacity: 0.85;
}

.quick-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    text-align: center;
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    transition: all var(--transition);
    cursor: pointer;
    text-decoration: none;
}

.quick-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.quick-link svg {
    width: 24px;
    height: 24px;
    color: var(--text-muted);
}

/* ── Generate page ───────────────────────────────────────────────────────── */
.gen-panel {
    background: var(--surface);
    border-right: 1px solid var(--border);
    min-height: calc(100vh - 64px);
    padding: 24px;
}

.gen-panel:last-child {
    border-right: none;
}

.gen-layout {
    display: grid;
    grid-template-columns: 30% 40% 30%;
    min-height: calc(100vh - 64px);
}

.gen-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.gen-section-title h3 {
    font-size: 16px;
    font-weight: 600;
}

.type-tabs {
    display: flex;
    gap: 4px;
    background: #f4f4f4;
    border-radius: var(--radius-sm);
    padding: 4px;
}

.type-tab {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    background: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
    color: var(--text-muted);
}

.type-tab.active {
    background: var(--surface);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

.concept-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition);
    margin-bottom: 8px;
}

.concept-option:hover {
    border-color: var(--accent);
}

.concept-option.active {
    border-color: var(--accent);
    background: var(--accent-light);
}

.concept-thumb {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: #eee;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.concept-name {
    font-size: 14px;
    font-weight: 500;
}

.concept-desc {
    font-size: 12px;
    color: var(--text-muted);
}

/* ── Photo previews ──────────────────────────────────────────────────────── */
.photo-previews {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.photo-preview {
    width: 72px;
    height: 72px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--border);
}

.photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-preview-remove {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 20px;
    height: 20px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Results area ────────────────────────────────────────────────────────── */
.results-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    color: var(--text-light);
    font-size: 15px;
}

.result-grid {
    -webkit-column-count: 2;
    column-count: 2;
    -webkit-column-gap: 12px;
    column-gap: 12px;
}

.result-media-wrap {
    position: relative;
    cursor: pointer;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg);
    min-height: 80px;
    line-height: 0;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
    break-inside: avoid;
    margin-bottom: 12px;
    display: inline-block;
    width: 100%;
}

.result-media-wrap img,
.result-media-wrap video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius-md);
}

/* Loading skeleton */
.result-skeleton {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(90deg, var(--bg) 25%, #e8e8e8 50%, var(--bg) 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.4s infinite;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes skeletonShimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Eye hover overlay */
.result-hover-overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, opacity 0.2s ease;
    border-radius: var(--radius-md);
    opacity: 0;
    pointer-events: none;
}

.result-media-wrap:hover .result-hover-overlay {
    opacity: 1;
    background: rgba(0, 0, 0, 0.28);
}

.result-eye-icon {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.92);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transform: scale(0.85);
    transition: transform 0.18s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.result-media-wrap:hover .result-eye-icon {
    transform: scale(1);
}

/* Legacy (used in project_detail video wraps) */
.result-video-wrap {
    position: relative;
    background: #0a0a0a;
    line-height: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.result-video {
    width: 100%;
    height: auto;
    display: block;
}

.result-actions {
    display: flex;
    gap: 6px;
    padding: 8px;
    background: var(--surface);
    border-top: 1px solid var(--border);
}

/* ── Spinner ─────────────────────────────────────────────────────────────── */
.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* ── Alerts / Messages ───────────────────────────────────────────────────── */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    margin-bottom: 16px;
}

.alert-success {
    background: var(--accent-light);
    color: var(--accent);
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #ffebee;
    color: var(--danger);
    border: 1px solid #f5c6cb;
}

.alert-info {
    background: #e3f2fd;
    color: #1565C0;
    border: 1px solid #bbdefb;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
    .gen-layout {
        grid-template-columns: 1fr;
    }

    .gen-panel {
        border-right: none;
        border-bottom: 1px solid var(--border);
        min-height: auto;
    }

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

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

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

    h1 {
        font-size: 36px;
    }

    h2 {
        font-size: 26px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .section {
        padding: 48px 0;
    }

    .navbar-nav {
        display: none;
    }

    .navbar-toggle {
        display: flex;
    }

    .navbar-nav.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--surface);
        border-bottom: 1px solid var(--border);
        padding: 16px 24px;
        gap: 12px;
        box-shadow: var(--shadow-md);
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    h1 {
        font-size: 28px;
    }

    h2 {
        font-size: 22px;
    }

    .pricing-card {
        padding: 20px;
    }

    .comparison-table {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .btn-lg {
        padding: 14px 24px;
        font-size: 15px;
    }

    .stat-number {
        font-size: 32px;
    }
}

/* ── Result action modal ─────────────────────────────────────────────────── */
.result-modal-overlay {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeInOverlay 0.18s ease;
}

.result-modal {
    background: var(--surface);
    border-radius: var(--radius-md);
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
    display: grid;
    grid-template-columns: 1fr 280px;
    width: 900px;
    max-width: 96vw;
    max-height: 92vh;
    overflow: hidden;
    animation: slideUpModal 0.22s ease;
}

.result-modal-preview {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0a0a0a;
    overflow: hidden;
    line-height: 0;
    min-height: 0;
}

.result-modal-preview img {
    width: 100%;
    height: 100%;
    display: block;
    max-height: 92vh;
    object-fit: contain;
}

.result-modal-preview video {
    width: 100%;
    height: 100%;
    display: block;
    max-height: 92vh;
    background: #0a0a0a;
    object-fit: contain;
}

.result-modal-body {
    padding: 20px;
    overflow-y: auto;
    border-left: 1px solid var(--border);
}

.result-modal-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.result-modal-meta {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.result-modal-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    font-size: 12px;
    line-height: 1.4;
}

.result-modal-meta-label {
    color: var(--text-muted);
    flex-shrink: 0;
}

.result-modal-meta-value {
    color: var(--text-primary);
    text-align: right;
    word-break: break-word;
    max-width: 65%;
}

.result-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.result-modal-action-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1.5px solid var(--border);
    background: var(--bg);
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition);
    font-family: inherit;
    width: 100%;
    text-align: left;
}

.result-modal-action-btn:hover {
    border-color: var(--accent);
    background: var(--accent-light);
    color: var(--accent);
}

.result-modal-action-btn.primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.result-modal-action-btn.primary:hover {
    background: rgb(var(--accent-hover-rgb));
    border-color: rgb(var(--accent-hover-rgb));
    color: #fff;
}

.result-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--transition);
    z-index: 1;
}

.result-modal-close:hover {
    background: rgba(0,0,0,0.8);
}

/* ── AI idea chips ───────────────────────────────────────────────────────── */
.ai-ideas-container {
    margin-top: 10px;
}

.ai-ideas-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.ai-ideas-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ai-idea-chip {
    padding: 5px 11px;
    border: 1.5px solid var(--border);
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s ease;
    background: var(--bg);
    color: var(--text-muted);
    font-family: inherit;
    line-height: 1.4;
    animation: chipAppear 0.2s ease both;
}

.ai-idea-chip:nth-child(1) { animation-delay: 0.02s; }
.ai-idea-chip:nth-child(2) { animation-delay: 0.06s; }
.ai-idea-chip:nth-child(3) { animation-delay: 0.10s; }
.ai-idea-chip:nth-child(4) { animation-delay: 0.14s; }
.ai-idea-chip:nth-child(5) { animation-delay: 0.18s; }

.ai-idea-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-light);
}

.ai-idea-chip.selected {
    border-color: var(--accent);
    background: var(--accent);
    color: #fff;
}

/* ── Animations ──────────────────────────────────────────────────────────── */
@keyframes fadeInOverlay {
    from { opacity: 0; }
    to   { opacity: 1; }
}

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

@keyframes chipAppear {
    from { transform: scale(0.8); opacity: 0; }
    to   { transform: scale(1);   opacity: 1; }
}

/* gen-layout responsive override */
@media (max-width: 1300px) {
    .gen-layout {
        grid-template-columns: 30% 40% 30%;
    }
}

@media (max-width: 1200px) {
    .gen-layout {
        grid-template-columns: 30% 40% 30%;
    }
}

@media (max-width: 600px) {
    .result-grid {
        -webkit-column-count: 1;
        column-count: 1;
    }
}

/* ── Improve feature ─────────────────────────────────────────────────────── */
.result-modal-improve {
    margin-bottom: 12px;
}

.improve-btn {
    width: 100%;
    justify-content: center;
    background: var(--accent-light, rgba(99,102,241,0.1));
    border-color: var(--accent);
    color: var(--accent);
}

.improve-btn:hover {
    background: var(--accent);
    color: #fff;
}

/* ── Improve Modal ───────────────────────────────────────────────────────── */
.improve-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    z-index: 3000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 48px;
    overflow-y: auto;
}

.improve-dialog {
    background: var(--surface);
    border-radius: var(--radius-md);
    box-shadow: 0 24px 72px rgba(0,0,0,0.35);
    width: 480px;
    max-width: 95vw;
    overflow: hidden;
    animation: slideUpModal 0.2s ease;
}

.improve-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

.improve-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.improve-close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 16px;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: background 0.15s;
}
.improve-close:hover { background: var(--bg-hover); }

.improve-source-wrap {
    padding: 16px 20px 0;
}

.improve-source-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.improve-source-img {
    width: 100%;
    max-height: 200px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg);
}

.improve-form {
    padding: 16px 20px 20px;
}

.improve-form-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.improve-textarea {
    width: 100%;
    padding: 10px 12px;
    font-size: 13px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    resize: none;
    box-sizing: border-box;
    line-height: 1.5;
    transition: border-color 0.15s;
}
.improve-textarea:focus { outline: none; border-color: var(--accent); }

.improve-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.improve-chip {
    font-size: 12px;
    padding: 4px 10px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 20px;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.15s;
}
.improve-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-light, rgba(99,102,241,0.08));
}

.improve-loading {
    padding: 40px 20px 32px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

.improve-ai-anim {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}
.improve-ai-orb {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, var(--accent), rgba(99,102,241,0.3));
    animation: improve-orb-pulse 2s ease-in-out infinite;
}
.improve-ai-ring {
    position: absolute;
    border-radius: 50%;
    border: 1.5px solid var(--accent);
    opacity: 0;
    animation: improve-ring-out 2.4s ease-out infinite;
}
.improve-ai-ring-1 { width: 80px; height: 80px; animation-delay: 0s; }
.improve-ai-ring-2 { width: 80px; height: 80px; animation-delay: 0.8s; }
.improve-ai-ring-3 { width: 80px; height: 80px; animation-delay: 1.6s; }
.improve-ai-icon {
    position: relative;
    z-index: 1;
    color: #fff;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.3));
}
@keyframes improve-orb-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.06); opacity: 0.85; }
}
@keyframes improve-ring-out {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(2); opacity: 0; }
}

.improve-loading-bars {
    display: flex;
    gap: 5px;
    margin-bottom: 16px;
}
.improve-bar {
    width: 6px;
    height: 22px;
    border-radius: 3px;
    background: var(--accent);
    animation: improve-bar-bounce 1s ease-in-out infinite;
}
.improve-bar:nth-child(2) { animation-delay: 0.15s; }
.improve-bar:nth-child(3) { animation-delay: 0.3s; }
@keyframes improve-bar-bounce {
    0%, 100% { transform: scaleY(0.5); opacity: 0.5; }
    50% { transform: scaleY(1); opacity: 1; }
}

.improve-loading-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 4px;
}
.improve-loading-sub {
    font-size: 11px;
    color: var(--text-muted);
    margin: 0;
    opacity: 0.65;
}

.improve-result {
    padding: 16px 20px 20px;
}

.improve-result-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.improve-result-img {
    width: 100%;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    margin-bottom: 12px;
}

.improve-result-actions {
    display: flex;
    gap: 8px;
}

.improve-error {
    padding: 20px;
    text-align: center;
}

/* Ops dashboard */
.ops-shell {
    position: relative;
}

.ops-topbar {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    align-items: stretch;
    margin-bottom: 24px;
    padding: 22px 24px;
    border-radius: 18px;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
    background: rgba(var(--surface-rgb), 0.96);
    box-shadow: 0 18px 40px rgba(19, 22, 31, 0.06);
}

.ops-topbar-main {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ops-topbar-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 10px;
    border-radius: 999px;
    background: #101828;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.ops-topbar-copy {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ops-topbar-title {
    margin: 0;
    font-size: 38px;
    letter-spacing: -0.03em;
}

.ops-topbar-text {
    max-width: 720px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
}

.ops-topbar-side {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-end;
    justify-content: space-between;
}

.ops-topbar-meta {
    min-width: 220px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #f6f8fb;
    border: 1px solid rgba(var(--text-primary-rgb), 0.06);
    text-align: right;
}

.ops-topbar-meta-label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.ops-headline-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.ops-headline-card {
    padding: 18px 18px 16px;
    border-radius: 16px;
    background: #fff;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
    box-shadow: 0 10px 24px rgba(18, 23, 33, 0.04);
}

.ops-headline-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.ops-headline-value {
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 8px;
}

.ops-headline-meta {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}

.ops-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.75fr) minmax(320px, 0.85fr);
    gap: 18px;
    align-items: start;
}

.ops-main,
.ops-side {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.ops-panel {
    border-radius: 18px;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
    background: rgba(var(--surface-rgb), 0.98);
    box-shadow: 0 16px 36px rgba(18, 23, 33, 0.05);
    overflow: hidden;
}

.ops-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border-bottom: 1px solid rgba(var(--text-primary-rgb), 0.08);
    background: linear-gradient(180deg, rgba(246, 248, 251, 0.9), rgba(255, 255, 255, 0.92));
}

.ops-panel-body {
    padding: 18px 20px 20px;
}

.ops-panel-kicker {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.ops-panel-title {
    margin: 0;
    font-size: 20px;
}

.ops-panel-note {
    color: var(--text-muted);
    font-size: 12px;
    text-align: right;
}

.ops-health-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.ops-health-card,
.ops-worker-card,
.ops-stat-panel,
.ops-queue-card {
    border-radius: 14px;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
    background: #fff;
}

.ops-health-card {
    padding: 14px;
}

.ops-health-card--ok {
    border-color: rgba(34, 197, 94, 0.18);
    background: linear-gradient(180deg, rgba(240, 253, 244, 0.8), #fff);
}

.ops-health-card--warn {
    border-color: rgba(245, 158, 11, 0.2);
    background: linear-gradient(180deg, rgba(255, 247, 237, 0.85), #fff);
}

.ops-health-card--fail {
    border-color: rgba(239, 68, 68, 0.22);
    background: linear-gradient(180deg, rgba(254, 242, 242, 0.88), #fff);
}

.ops-health-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.ops-health-state {
    margin-left: auto;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    background: #eef2f7;
    color: #475467;
}

.ops-health-state--ok {
    background: #dcfce7;
    color: #166534;
}

.ops-health-state--warn {
    background: #fef3c7;
    color: #b45309;
}

.ops-health-state--fail {
    background: #fee2e2;
    color: #b91c1c;
}

.ops-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.ops-status-dot--ok {
    background: #22c55e;
    box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.14);
}

.ops-status-dot--warn {
    background: #f59e0b;
    box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.14);
}

.ops-status-dot--fail {
    background: #ef4444;
    box-shadow: 0 0 0 5px rgba(239, 68, 68, 0.14);
}

.ops-health-label,
.ops-block-title {
    font-size: 14px;
    font-weight: 700;
}

.ops-health-summary {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
}

.ops-health-detail,
.ops-worker-meta,
.ops-action-note,
.ops-empty {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}

.ops-two-col,
.ops-three-col {
    display: grid;
    gap: 12px;
}

.ops-two-col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ops-three-col {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ops-worker-list,
.ops-provider-list,
.ops-action-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ops-worker-card,
.ops-stat-panel {
    padding: 14px;
}

.ops-stat-panel {
    background: linear-gradient(180deg, #ffffff 0%, #fbfcfd 100%);
}

.ops-worker-row,
.ops-provider-row,
.ops-kv,
.ops-queue-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ops-worker-name,
.ops-queue-name {
    font-weight: 700;
}

.ops-worker-metric {
    font-weight: 800;
    font-size: 13px;
}

.ops-progress {
    height: 6px;
    border-radius: 999px;
    background: rgba(var(--text-primary-rgb), 0.07);
    overflow: hidden;
    margin: 10px 0 7px;
}

.ops-progress-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #111827, #334155);
}

.ops-queue-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.ops-queue-card {
    padding: 14px;
}

.ops-queue-caption {
    margin-top: 4px;
    font-size: 11px;
    color: var(--text-muted);
}

.ops-queue-depth {
    font-size: 26px;
    font-weight: 800;
}

.ops-stat-panel {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 18px;
}

.ops-kv {
    font-size: 14px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(var(--text-primary-rgb), 0.08);
}

.ops-kv:last-child {
    border-bottom: none;
}

.ops-kv span {
    color: var(--text-muted);
}

.ops-kv strong {
    font-size: 14px;
    font-weight: 800;
}

.ops-tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 8px;
}

.ops-metric-stack {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.ops-metric-tile {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
    border-radius: 14px;
    background: #f7f9fc;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
    min-height: 86px;
    justify-content: space-between;
}

.ops-metric-tile--wide {
    grid-column: 1 / -1;
}

.ops-metric-tile-label {
    font-size: 11px;
    line-height: 1.5;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.ops-metric-tile-value {
    font-size: 24px;
    line-height: 1.1;
    font-weight: 800;
    color: var(--text-primary);
    word-break: break-word;
}

.ops-subsection {
    padding-top: 6px;
}

.ops-subsection-label {
    margin-bottom: 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.ops-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 999px;
    background: #eef2f7;
    color: #344054;
    font-size: 11px;
    font-weight: 700;
}

.ops-tag--muted {
    background: #f4f6f8;
    color: #475467;
}

.ops-status-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    text-transform: lowercase;
    background: #eef2f7;
    color: #475467;
}

.ops-status-pill--done {
    background: #dcfce7;
    color: #166534;
}

.ops-status-pill--failed {
    background: #fee2e2;
    color: #b91c1c;
}

.ops-status-pill--processing {
    background: #fef3c7;
    color: #b45309;
}

.ops-status-pill--pending {
    background: #e0f2fe;
    color: #075985;
}

.ops-table-wrap {
    overflow-x: auto;
}

.ops-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    table-layout: fixed;
}

.ops-table th,
.ops-table td {
    text-align: left;
    padding: 12px 10px;
    border-bottom: 1px solid rgba(var(--text-primary-rgb), 0.08);
    vertical-align: top;
}

.ops-table th {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    background: #f8fafc;
}

.ops-table td {
    word-break: break-word;
}

.ops-table tbody tr:nth-child(even) {
    background: #fbfcfd;
}

.ops-fact-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ops-fact-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px 14px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
}

.ops-fact-row span {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.ops-fact-row strong {
    font-size: 14px;
    font-weight: 800;
    color: var(--text-primary);
    word-break: break-word;
}

.ops-action-card {
    padding: 12px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid rgba(var(--text-primary-rgb), 0.08);
}

.ops-provider-row {
    padding: 9px 0;
    border-bottom: 1px solid rgba(var(--text-primary-rgb), 0.08);
}

.ops-provider-row:last-child {
    border-bottom: none;
}

.ops-action-disabled {
    margin-top: 6px;
    color: var(--danger);
}

@media (max-width: 1200px) {
    .ops-headline-grid,
    .ops-health-grid,
    .ops-three-col {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ops-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .ops-topbar {
        flex-direction: column;
    }

    .ops-topbar-side {
        width: 100%;
        align-items: stretch;
    }

    .ops-topbar-meta {
        text-align: left;
    }

    .ops-headline-grid,
    .ops-health-grid,
    .ops-two-col,
    .ops-three-col,
    .ops-queue-list,
    .ops-metric-stack {
        grid-template-columns: 1fr;
    }

    .ops-panel-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .ops-panel-note {
        text-align: left;
    }
}
