/* OmniTools product-family themes — 2026-10-25
   Light is the public default. Dark remains an explicit visitor preference. */

:root,
html[data-omni-section="platform"] {
    --omni-accent: #2563eb;
    --omni-accent-hover: #1d4ed8;
    --omni-accent-rgb: 37, 99, 235;
    --omni-secondary: #7c3aed;
    --omni-soft: #eff6ff;
    --omni-soft-2: #f5f3ff;
    --omni-canvas: #f8fafc;
    --omni-card-radius: 1.25rem;
    --omni-card-border: rgba(37, 99, 235, .14);
}

html[data-omni-section="pdf"] {
    --omni-accent: #dc2626;
    --omni-accent-hover: #b91c1c;
    --omni-accent-rgb: 220, 38, 38;
    --omni-secondary: #f97316;
    --omni-soft: #fff1f2;
    --omni-soft-2: #fff7ed;
    --omni-canvas: #fffafa;
    --omni-card-radius: 1.15rem;
    --omni-card-border: rgba(220, 38, 38, .16);
}

html[data-omni-section="documents"] {
    --omni-accent: #1d4ed8;
    --omni-accent-hover: #1e40af;
    --omni-accent-rgb: 29, 78, 216;
    --omni-secondary: #0891b2;
    --omni-soft: #eff6ff;
    --omni-soft-2: #ecfeff;
    --omni-canvas: #f8fbff;
    --omni-card-radius: .9rem;
    --omni-card-border: rgba(29, 78, 216, .16);
}

html[data-omni-section="image"] {
    --omni-accent: #ea580c;
    --omni-accent-hover: #9a3412;
    --omni-accent-rgb: 234, 88, 12;
    --omni-secondary: #db2777;
    --omni-soft: #fff7ed;
    --omni-soft-2: #fdf2f8;
    --omni-canvas: #fffcf7;
    --omni-card-radius: 1.55rem;
    --omni-card-border: rgba(234, 88, 12, .18);
}

html[data-omni-section="video"] {
    --omni-accent: #6d28d9;
    --omni-accent-hover: #4c1d95;
    --omni-accent-rgb: 109, 40, 217;
    --omni-secondary: #2563eb;
    --omni-soft: #f5f3ff;
    --omni-soft-2: #eff6ff;
    --omni-canvas: #fbfaff;
    --omni-card-radius: 1.1rem;
    --omni-card-border: rgba(109, 40, 217, .17);
}

html[data-omni-section="developer"] {
    --omni-accent: #0f766e;
    --omni-accent-hover: #115e59;
    --omni-accent-rgb: 15, 118, 110;
    --omni-secondary: #0369a1;
    --omni-soft: #f0fdfa;
    --omni-soft-2: #ecfeff;
    --omni-canvas: #f7fffd;
    --omni-card-radius: .75rem;
    --omni-card-border: rgba(15, 118, 110, .18);
}

html[data-omni-section="study"] {
    --omni-accent: #15803d;
    --omni-accent-hover: #166534;
    --omni-accent-rgb: 21, 128, 61;
    --omni-secondary: #ca8a04;
    --omni-soft: #f0fdf4;
    --omni-soft-2: #fefce8;
    --omni-canvas: #fbfffb;
    --omni-card-radius: 1.05rem;
    --omni-card-border: rgba(21, 128, 61, .17);
}

html[data-omni-section="career"] {
    --omni-accent: #4338ca;
    --omni-accent-hover: #3730a3;
    --omni-accent-rgb: 67, 56, 202;
    --omni-secondary: #0284c7;
    --omni-soft: #eef2ff;
    --omni-soft-2: #f0f9ff;
    --omni-canvas: #f9faff;
    --omni-card-radius: 1.35rem;
    --omni-card-border: rgba(67, 56, 202, .16);
}

html[data-omni-section="portfolio"] {
    --omni-accent: #a21caf;
    --omni-accent-hover: #86198f;
    --omni-accent-rgb: 162, 28, 175;
    --omni-secondary: #e11d48;
    --omni-soft: #fdf4ff;
    --omni-soft-2: #fff1f2;
    --omni-canvas: #fffaff;
    --omni-card-radius: 1.7rem;
    --omni-card-border: rgba(162, 28, 175, .16);
}

body[data-theme-style="light"] {
    color: #0f172a;
    background:
        radial-gradient(circle at 8% 0, rgba(var(--omni-accent-rgb), .065), transparent 28rem),
        linear-gradient(180deg, #fff 0, var(--omni-canvas) 24rem, #fff 100%);
}

body[data-theme-style="light"] .navbar,
body[data-theme-style="light"] .app-footer {
    background: rgba(255, 255, 255, .92);
    border-color: rgba(var(--omni-accent-rgb), .11);
    backdrop-filter: blur(14px);
}

body[data-theme-style="light"] .index-background.omni-category-hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 14% 18%, rgba(var(--omni-accent-rgb), .16), transparent 22rem),
        linear-gradient(135deg, var(--omni-soft), #fff 54%, var(--omni-soft-2));
    border-bottom: 1px solid var(--omni-card-border);
}

body[data-theme-style="light"] .index-background.omni-category-hero::after {
    content: "";
    position: absolute;
    inset-inline-end: -4rem;
    inset-block-end: -7rem;
    width: 18rem;
    height: 18rem;
    border: 2.5rem solid rgba(var(--omni-accent-rgb), .055);
    border-radius: 50%;
    pointer-events: none;
}

body[data-theme-style="light"] .omni-category-hero-icon,
body[data-theme-style="light"] .omni-tool-page-icon,
body[data-theme-style="light"] .omni-tool-icon {
    color: var(--omni-accent) !important;
    background: var(--omni-soft) !important;
    border: 1px solid rgba(var(--omni-accent-rgb), .15);
    box-shadow: 0 .55rem 1.35rem rgba(var(--omni-accent-rgb), .11);
}

body[data-theme-style="light"] .omni-category-page-title,
body[data-theme-style="light"] .omni-tool-page-title,
body[data-theme-style="light"] .omni-section-title {
    color: #0f172a !important;
}

body[data-theme-style="light"] a:not(.btn):not(.dropdown-item):not(.nav-link):not(.navbar-brand) {
    color: var(--omni-accent-hover);
}

body[data-theme-style="light"] .text-primary,
body[data-theme-style="light"] .nav-link.text-primary,
body[data-theme-style="light"] .nav-link.omni-nav-highlight {
    color: var(--omni-accent-hover) !important;
}

body[data-theme-style="light"] .card h2,
body[data-theme-style="light"] .card h3,
body[data-theme-style="light"] .card h4,
body[data-theme-style="light"] .card h5,
body[data-theme-style="light"] .card h6,
body[data-theme-style="light"] .card h2 a,
body[data-theme-style="light"] .card h3 a,
body[data-theme-style="light"] .card h4 a,
body[data-theme-style="light"] .card h5 a,
body[data-theme-style="light"] .card h6 a {
    color: #0f172a !important;
}

body[data-theme-style="light"] .omni-tool-category-pill {
    color: var(--omni-accent);
    background: var(--omni-soft);
    border: 1px solid rgba(var(--omni-accent-rgb), .16);
}

body[data-theme-style="light"] .card,
body[data-theme-style="light"] .omni-benefit-card,
body[data-theme-style="light"] .omni-product-path,
body[data-theme-style="light"] .omnitools-search-card {
    border-color: var(--omni-card-border);
}

body[data-theme-style="light"] .omni-tool-card,
body[data-theme-style="light"] .omni-category-card,
body[data-theme-style="light"] .document-tool-card,
body[data-theme-style="light"] .omni-related-card,
body[data-theme-style="light"] .omni-search-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--omni-card-radius);
    border-color: var(--omni-card-border) !important;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 .7rem 2rem rgba(15, 23, 42, .055);
}

body[data-theme-style="light"] .omni-tool-card::before,
body[data-theme-style="light"] .document-tool-card::before,
body[data-theme-style="light"] .omni-related-card::before {
    content: "";
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    width: .25rem;
    background: linear-gradient(180deg, var(--omni-accent), var(--omni-secondary));
    opacity: .9;
}

body[data-theme-style="light"] .omni-tool-card,
body[data-theme-style="light"] .omni-related-card,
body[data-theme-style="light"] .omni-product-path,
body[data-theme-style="light"] .omni-benefit-card {
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

body[data-theme-style="light"] .omni-tool-card:hover,
body[data-theme-style="light"] .omni-tool-card:focus-within,
body[data-theme-style="light"] .omni-related-card:hover,
body[data-theme-style="light"] .omni-related-card:focus-within,
body[data-theme-style="light"] .omni-product-path:hover,
body[data-theme-style="light"] .omni-product-path:focus-within,
body[data-theme-style="light"] .omni-benefit-card:hover,
body[data-theme-style="light"] .omni-benefit-card:focus-within {
    transform: translateY(-3px);
    border-color: rgba(var(--omni-accent-rgb), .35) !important;
    box-shadow: 0 1rem 2.35rem rgba(var(--omni-accent-rgb), .12);
}

body[data-theme-style="light"] .btn-primary,
body[data-theme-style="light"] .custom-control-input:checked ~ .custom-control-label::before {
    color: #fff !important;
    background: linear-gradient(135deg, var(--omni-accent), var(--omni-secondary));
    border-color: var(--omni-accent);
    box-shadow: 0 .45rem 1.1rem rgba(var(--omni-accent-rgb), .2);
}

body[data-theme-style="light"] .btn-primary:hover,
body[data-theme-style="light"] .btn-primary:focus {
    color: #fff !important;
    background: var(--omni-accent-hover);
    border-color: var(--omni-accent-hover);
    box-shadow: 0 0 0 .2rem rgba(var(--omni-accent-rgb), .22);
}

body[data-theme-style="light"] .btn-outline-primary {
    color: var(--omni-accent-hover) !important;
    border-color: var(--omni-accent-hover) !important;
}

body[data-theme-style="light"] .btn-outline-primary:hover,
body[data-theme-style="light"] .btn-outline-primary:focus {
    color: #fff !important;
    background: var(--omni-accent-hover) !important;
}

/* The image-category CTA keeps its existing bright inline orange surface.
   Dark ink is required there to preserve WCAG AA contrast. */
body[data-theme-style="light"][data-omni-section="image"] .index-button.btn-primary[style],
body[data-theme-style="light"][data-omni-section="developer"] .index-button.btn-primary[style],
body[data-theme-style="light"][data-omni-section="study"] .index-button.btn-primary[style] {
    color: #111827 !important;
}

body[data-theme-style="light"] a:not(.btn):focus-visible,
body[data-theme-style="light"] button:focus-visible,
body[data-theme-style="light"] input:focus-visible,
body[data-theme-style="light"] select:focus-visible,
body[data-theme-style="light"] textarea:focus-visible {
    outline: 3px solid rgba(var(--omni-accent-rgb), .38);
    outline-offset: 3px;
}

body[data-theme-style="light"] .form-control:focus,
body[data-theme-style="light"] .custom-select:focus {
    border-color: var(--omni-accent);
    box-shadow: 0 0 0 .2rem rgba(var(--omni-accent-rgb), .14);
}

/* PDF: paper-like red signature and crisp document geometry. */
body[data-theme-style="light"][data-omni-section="pdf"] .omni-tool-card,
body[data-theme-style="light"][data-omni-section="pdf"] .document-tool-card {
    background-image: linear-gradient(90deg, rgba(220, 38, 38, .028) 1px, transparent 1px);
    background-size: 1.25rem 100%;
}

body[data-theme-style="light"][data-omni-section="pdf"] .document-dropzone {
    border-color: rgba(220, 38, 38, .32);
    background: linear-gradient(145deg, #fff, #fff7f7);
}

/* Documents: structured blue edge and subtle ruled-paper rhythm. */
body[data-theme-style="light"][data-omni-section="documents"] .omni-category-hero,
body[data-theme-style="light"][data-omni-section="documents"] .document-tool-card {
    background-image:
        linear-gradient(rgba(29, 78, 216, .035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(29, 78, 216, .028) 1px, transparent 1px);
    background-size: 100% 1.75rem, 1.75rem 100%;
}

/* Images: gallery-like soft corners and color halo. */
body[data-theme-style="light"][data-omni-section="image"] .omni-tool-card::after,
body[data-theme-style="light"][data-omni-section="image"] .document-tool-card::after {
    content: "";
    position: absolute;
    inset-inline-end: -3rem;
    inset-block-start: -3rem;
    width: 8rem;
    height: 8rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(219, 39, 119, .13), transparent 68%);
    pointer-events: none;
}

/* Video: cinematic stripe while retaining the light workspace. */
body[data-theme-style="light"][data-omni-section="video"] .omni-category-hero::before {
    content: "";
    position: absolute;
    inset: .8rem 0 auto;
    height: .45rem;
    background: repeating-linear-gradient(90deg, var(--omni-accent) 0 .9rem, transparent .9rem 1.35rem);
    opacity: .24;
}

/* Developer: compact technical geometry, without reducing readability. */
body[data-theme-style="light"][data-omni-section="developer"] .omni-tool-card,
body[data-theme-style="light"][data-omni-section="developer"] .document-tool-card {
    box-shadow: .35rem .35rem 0 rgba(15, 118, 110, .075);
}

body[data-theme-style="light"][data-omni-section="developer"] .omni-tool-category-pill {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    letter-spacing: .02em;
}

/* Study: notebook dots and a warm achievement accent. */
body[data-theme-style="light"][data-omni-section="study"] .omni-category-hero,
body[data-theme-style="light"][data-omni-section="study"] .document-tool-card {
    background-image: radial-gradient(rgba(21, 128, 61, .085) .75px, transparent .75px);
    background-size: 1rem 1rem;
}

/* Career: confident indigo panels. */
body[data-theme-style="light"][data-omni-section="career"] .omni-category-hero,
body[data-theme-style="light"][data-omni-section="career"] .document-tool-card {
    background: linear-gradient(145deg, #fff, var(--omni-soft));
}

/* Portfolio: editorial spacing and a softer magenta frame. */
body[data-theme-style="light"][data-omni-section="portfolio"] .omni-tool-card,
body[data-theme-style="light"][data-omni-section="portfolio"] .document-tool-card {
    border-width: 1px;
    box-shadow: 0 1.15rem 3rem rgba(162, 28, 175, .1);
}

/* Homepage product families remain visually distinct on the shared canvas. */
body[data-theme-style="light"] #home-cv {
    --omni-accent: #4338ca;
    --omni-secondary: #0284c7;
    --omni-accent-rgb: 67, 56, 202;
    padding: clamp(2rem, 4vw, 3.5rem);
    border-radius: 1.6rem;
    background: linear-gradient(145deg, #eef2ff, #fff 62%);
}

body[data-theme-style="light"] #home-career {
    --omni-accent: #0f766e;
    --omni-secondary: #0369a1;
    --omni-accent-rgb: 15, 118, 110;
    padding: clamp(2rem, 4vw, 3.5rem);
    border-radius: 1.2rem;
    background: linear-gradient(145deg, #f0fdfa, #fff 62%);
}

body[data-theme-style="light"] #home-portfolio {
    --omni-accent: #a21caf;
    --omni-secondary: #e11d48;
    --omni-accent-rgb: 162, 28, 175;
    padding: clamp(2rem, 4vw, 3.5rem);
    border-radius: 2rem;
    background: linear-gradient(145deg, #fdf4ff, #fff 62%);
}

body[data-theme-style="light"] #home-pdf {
    --omni-accent: #dc2626;
    --omni-secondary: #f97316;
    --omni-accent-rgb: 220, 38, 38;
    padding: clamp(2rem, 4vw, 3.5rem);
    border-radius: 1.15rem;
    background: linear-gradient(145deg, #fff1f2, #fff 62%);
}

body[data-theme-style="light"] #home-cv .omni-tool-icon,
body[data-theme-style="light"] #home-career .omni-tool-icon,
body[data-theme-style="light"] #home-portfolio .omni-tool-icon,
body[data-theme-style="light"] #home-pdf .omni-tool-icon {
    color: var(--omni-accent) !important;
    background: #fff !important;
    border-color: rgba(var(--omni-accent-rgb), .18);
}

/* Dark remains supported after a visitor explicitly chooses it. */
body[data-theme-style="dark"] {
    --omni-dark-surface: #111827;
    --omni-dark-border: rgba(255, 255, 255, .12);
}

body[data-theme-style="dark"] .omni-category-hero,
body[data-theme-style="dark"] .omni-tool-card,
body[data-theme-style="dark"] .document-tool-card,
body[data-theme-style="dark"] .omni-related-card {
    border-color: var(--omni-dark-border) !important;
}

body[data-theme-style="dark"] .omni-category-hero-icon,
body[data-theme-style="dark"] .omni-tool-page-icon,
body[data-theme-style="dark"] .omni-tool-icon,
body[data-theme-style="dark"] .omni-tool-category-pill {
    color: #fff !important;
    background: rgba(var(--omni-accent-rgb), .3) !important;
    border-color: rgba(255, 255, 255, .15);
}

@media (max-width: 767.98px) {
    body[data-theme-style="light"] #home-cv,
    body[data-theme-style="light"] #home-career,
    body[data-theme-style="light"] #home-portfolio,
    body[data-theme-style="light"] #home-pdf {
        padding: 1.25rem;
        border-radius: 1.15rem;
    }

    body[data-theme-style="light"] .omni-tool-card:hover,
    body[data-theme-style="light"] .omni-tool-card:focus-within,
    body[data-theme-style="light"] .omni-benefit-card:hover,
    body[data-theme-style="light"] .omni-benefit-card:focus-within {
        transform: translateY(-1px);
    }
}

@media (prefers-reduced-motion: reduce) {
    body[data-theme-style="light"] .omni-tool-card,
    body[data-theme-style="light"] .omni-related-card,
    body[data-theme-style="light"] .omni-product-path,
    body[data-theme-style="light"] .omni-benefit-card {
        transition: none;
    }
}

@media print {
    body {
        background: #fff !important;
    }

    .omni-tool-card,
    .document-tool-card,
    .omni-related-card {
        box-shadow: none !important;
    }
}
