

:root {

    --color-primary-900: #0a2e33;
    --color-primary-800: #0E4751;
    --color-primary-700: #145a66;
    --color-primary-600: #1c696a;
    --color-primary-500: #027377;
    --color-primary-400: #00A291;
    --color-primary-300: #3dbdad;
    --color-primary-200: #a3ddd4;
    --color-primary-100: #d1eeea;
    --color-primary-50:  #ebf3f3;

    --color-accent-600: #c77820;
    --color-accent-500: #e8952e;
    --color-accent-400: #f0ad4e;
    --color-accent-300: #f5c882;

    --color-neutral-900: #1a1a2e;
    --color-neutral-800: #2a2a3d;
    --color-neutral-700: #3d3d56;
    --color-neutral-600: #555570;
    --color-neutral-500: #71718a;
    --color-neutral-400: #9494a8;
    --color-neutral-300: #b8b8c8;
    --color-neutral-200: #dddde8;
    --color-neutral-100: #f0f0f5;
    --color-neutral-50:  #f8f8fb;

    --color-success: #16a34a;
    --color-warning: #eab308;
    --color-danger:  #dc2626;
    --color-info:    #027377;

    --shadow-sm: 0 1px 2px 0 rgba(10, 46, 51, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(10, 46, 51, 0.08), 0 2px 4px -2px rgba(10, 46, 51, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(10, 46, 51, 0.08), 0 4px 6px -4px rgba(10, 46, 51, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(10, 46, 51, 0.10), 0 8px 10px -6px rgba(10, 46, 51, 0.05);
    --shadow-brand: 0 0 2rem rgba(0, 0, 0, 0.08), 1rem 1rem 0 -0.4rem var(--color-primary-100);

    --font-heading: 'Inter', system-ui, -apple-system, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;

    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    color: var(--color-neutral-800);
}

@keyframes gradient-shift {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.hero-gradient {
    background: linear-gradient(135deg,
        var(--color-primary-900) 0%,
        var(--color-primary-800) 25%,
        var(--color-primary-700) 50%,
        var(--color-primary-800) 75%,
        var(--color-primary-900) 100%);
    background-size: 200% 200%;
    animation: gradient-shift 12s ease infinite;
}

.hero-pattern {
    background-image:
        radial-gradient(circle at 20% 80%, rgba(0, 162, 145, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 162, 145, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.02) 0%, transparent 70%);
}

.brand-card {
    background: #fff;
    border-radius: 0.75rem;
    border: 1px solid var(--color-primary-100);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
}

.brand-card:hover {
    box-shadow: var(--shadow-brand);
    transform: translateY(-2px);
    border-color: var(--color-primary-200);
}

.action-card {
    background: #fff;
    border-radius: 0.75rem;
    border: 1px solid var(--color-primary-100);
    border-left: 4px solid var(--color-amber-500, #f59e0b);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    transition: all var(--transition-base);
}

.action-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
    border-color: var(--color-primary-200);
    border-left-color: var(--color-amber-600, #d97706);
}

.btn-primary {
    background-color: var(--color-primary-600);
    color: #fff;
    padding: 0.75rem 1.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    letter-spacing: 0.01em;
    transition: all var(--transition-fast);
    border: 2px solid transparent;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.btn-primary:hover {
    background-color: var(--color-primary-700);
    box-shadow: 0 4px 12px rgba(28, 105, 106, 0.3);
    transform: translateY(-1px);
}

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

.btn-accent {
    background-color: var(--color-accent-500);
    color: #fff;
    padding: 0.75rem 1.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    letter-spacing: 0.01em;
    transition: all var(--transition-fast);
    border: 2px solid transparent;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.btn-accent:hover {
    background-color: var(--color-accent-600);
    box-shadow: 0 4px 12px rgba(232, 149, 46, 0.3);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: #fff;
    padding: 0.75rem 1.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    border: 2px solid rgba(255, 255, 255, 0.4);
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.btn-outline:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.btn-outline-dark {
    background: transparent;
    color: var(--color-primary-600);
    padding: 0.75rem 1.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.9375rem;
    border: 2px solid var(--color-primary-200);
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.btn-outline-dark:hover {
    border-color: var(--color-primary-400);
    background: var(--color-primary-50);
}

.feature-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.feature-icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.feature-icon-teal {
    background: var(--color-primary-100);
    color: var(--color-primary-600);
}

.feature-icon-amber {
    background: #fef3cd;
    color: var(--color-accent-600);
}

.feature-icon-emerald {
    background: #d1fae5;
    color: #059669;
}

.nav-brand {
    background: #fff;
    border-bottom: 1px solid var(--color-primary-100);
    box-shadow: var(--shadow-sm);
}

.nav-link {
    color: var(--color-neutral-600);
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
    transition: all var(--transition-fast);
}

.nav-link:hover {
    color: var(--color-primary-600);
    background: var(--color-primary-50);
}

.nav-link-active {
    color: var(--color-primary-700);
    background: var(--color-primary-50);
}

.nav-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.5rem;
    color: var(--color-neutral-500);
    transition: all var(--transition-fast);
    cursor: pointer;
    border: none;
    background: transparent;
}
.nav-icon-btn:hover {
    color: var(--color-primary-600);
    background: var(--color-primary-50);
}

.avatar-initials {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    background: var(--color-primary-600);
    color: #fff;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all var(--transition-fast);
    line-height: 1;
}
.avatar-initials:hover {
    border-color: var(--color-primary-300);
    box-shadow: 0 0 0 2px var(--color-primary-100);
}

.profile-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 0.5rem);
    width: 16rem;
    background: #fff;
    border-radius: 0.75rem;
    border: 1px solid var(--color-neutral-200);
    box-shadow: var(--shadow-lg);
    z-index: 50;
    overflow: hidden;
}
.profile-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    color: var(--color-neutral-700);
    transition: background-color var(--transition-fast);
}
.profile-dropdown-item:hover {
    background-color: var(--color-neutral-50);
}

.help-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 22rem;
    max-width: 90vw;
    background: #fff;
    border-left: 1px solid var(--color-neutral-200);
    box-shadow: var(--shadow-xl);
    z-index: 51;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform var(--transition-base);
}
.help-drawer.help-drawer-open {
    transform: translateX(0);
}

.login-split-brand {
    background: linear-gradient(135deg, var(--color-primary-800) 0%, var(--color-primary-900) 100%);
    position: relative;
    overflow: hidden;
}

.login-split-brand::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 70%, rgba(0, 162, 145, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 70% 30%, rgba(0, 162, 145, 0.10) 0%, transparent 50%);
}

.section-light {
    background-color: var(--color-primary-50);
}

.input-brand {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--color-neutral-400);
    border-radius: 0.5rem;
    font-size: 0.9375rem;
    color: var(--color-neutral-800);
    background: #fff;
    transition: all var(--transition-fast);
    font-family: var(--font-body);
}

.input-brand:focus {
    outline: none;
    border-color: var(--color-primary-400);
    box-shadow: 0 0 0 3px rgba(0, 162, 145, 0.12);
}

.input-brand::placeholder {
    color: var(--color-neutral-400);
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(1.5rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fade-in-up 0.6s ease-out forwards;
}

.animate-delay-100 { animation-delay: 100ms; }
.animate-delay-200 { animation-delay: 200ms; }
.animate-delay-300 { animation-delay: 300ms; }
.animate-delay-400 { animation-delay: 400ms; }

.footer-brand {
    background: var(--color-neutral-900);
    color: var(--color-neutral-400);
}

.footer-brand a {
    color: var(--color-neutral-300);
    transition: color var(--transition-fast);
}

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

.app-body {
    background: var(--color-neutral-50);
}

.text-brand { color: var(--color-primary-600); }
.text-brand-light { color: var(--color-primary-400); }
.bg-brand { background-color: var(--color-primary-600); }
.bg-brand-dark { background-color: var(--color-primary-800); }
.bg-brand-light { background-color: var(--color-primary-50); }
.border-brand { border-color: var(--color-primary-200); }

/* Form-element defaults. `:where()` keeps specificity at (0,0,1) so any
   class-based override (e.g. Tailwind `px-3`, `pl-9`, `py-2`, `.input-brand`)
   still wins. Without this we'd clobber utility padding on the search bar,
   matters / meetings forms, sign_product settings, etc. */
input:where([type="text"], [type="email"], [type="password"], [type="number"], [type="date"], [type="datetime-local"], [type="month"], [type="week"], [type="time"], [type="url"], [type="tel"], [type="search"], :not([type])),
select,
textarea {
    border: 1px solid var(--color-neutral-300);
    min-height: 2.75rem;
    padding: 0.625rem 0.75rem;
    transition: border-color var(--transition-fast), background-color var(--transition-fast), box-shadow var(--transition-fast);
}

input:where([type="text"], [type="email"], [type="password"], [type="number"], [type="date"], [type="datetime-local"], [type="month"], [type="week"], [type="time"], [type="url"], [type="tel"], [type="search"], :not([type])):hover,
select:hover,
textarea:hover {
    border-color: var(--color-neutral-500);
    background-color: var(--tv-input-hover, var(--color-neutral-50));
}

input:where([type="text"], [type="email"], [type="password"], [type="number"], [type="date"], [type="datetime-local"], [type="month"], [type="week"], [type="time"], [type="url"], [type="tel"], [type="search"], :not([type])):focus,
select:focus,
textarea:focus {
    border-color: var(--color-primary-500);
    box-shadow: 0 0 0 3px rgba(2, 115, 119, 0.15);
    background-color: var(--tv-input-focus, #fff);
}

.input-borderless,
.input-borderless:hover,
.input-borderless:focus {
    border: none;
    outline: none;
    box-shadow: none;
    min-height: auto;
    background: transparent;
}

@keyframes htmx-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.htmx-spinner {
    animation: htmx-spin 1s linear infinite;
}

.entity-layout {
    min-height: calc(100vh - 4rem);
}

.htmx-indicator-toast {
    opacity: 0;
    transition: opacity 200ms ease;
}

/* The scroll bars follow the theme (L-16: Grafikai showed a white bar in the dark theme). */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--tv-scroll-track, var(--color-neutral-100)); }
::-webkit-scrollbar-thumb { background: var(--tv-scroll-thumb, var(--color-neutral-300)); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--tv-scroll-thumb-hover, var(--color-neutral-400)); }
::-webkit-scrollbar-corner { background: var(--tv-scroll-track, var(--color-neutral-100)); }

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    min-height: 2.375rem;
    padding: 0.5rem 0.625rem;
    font-size: 0.92rem;
    color: #2f4641;
    border-radius: 0.5rem;
    transition: background-color 150ms, color 150ms;
}
.sidebar-link:hover { background-color: #fff; color: #0E4751; }
.sidebar-link-active {
    background-color: #dff5f1 !important;
    color: #0E4751 !important;
    font-weight: 650;
}

.sidebar-icon {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
    fill: #9ca3af;
    stroke: none;
}
.sidebar-link-active .sidebar-icon,
.sidebar-link:hover .sidebar-icon { fill: #1c696a; }
.sidebar-section-btn:hover .sidebar-icon { fill: #6b7280; }

.sidebar-icon-blue { fill: none; stroke: #6b8db5; }
.sidebar-link-active .sidebar-icon-blue,
.sidebar-link:hover .sidebar-icon-blue { fill: none; stroke: #3b6ea0; }
.sidebar-section-btn:hover .sidebar-icon-blue { fill: none; stroke: #3b6ea0; }

.sidebar-icon-teal { fill: none; stroke: #2ba3a3; }
.sidebar-link-active .sidebar-icon-teal,
.sidebar-link:hover .sidebar-icon-teal { fill: none; stroke: #1c696a; }
.sidebar-section-btn:hover .sidebar-icon-teal { fill: none; stroke: #1c696a; }

.sidebar-section-btn {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    width: 100%;
    padding: 0.5rem 0.75rem;
    margin: 0 0.5rem;
    width: calc(100% - 1rem);
    min-height: 2.375rem;
    font-size: 0.92rem;
    font-weight: 500;
    color: #2f4641;
    border-radius: 0.5rem;
    transition: background-color 150ms, color 150ms;
}
.sidebar-section-btn:hover { background-color: #fff; color: #0E4751; }

.sidebar-submenu { padding: 0.25rem 0.75rem 0.25rem 1.75rem; }
.sidebar-sublink {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.4rem 0.5rem;
    font-size: 0.8125rem;
    color: #2f4641;
    border-radius: 0.5rem;
    transition: background-color 150ms, color 150ms;
}
.sidebar-sublink:hover { background-color: #fff; color: #0E4751; }

.product-sidebar-action-active {
    outline: 2px solid rgba(14, 71, 81, 0.28);
    outline-offset: -2px;
}

.sidebar-sublink-disabled {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.3rem 0.5rem;
    font-size: 0.8125rem;
    color: #9ca3af;
    cursor: default;
}
.sidebar-soon-badge {
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    padding: 0.125rem 0.375rem;
    border-radius: 9999px;
    background-color: #fef3c7;
    color: #92400e;
    opacity: 0;
    transition: opacity 150ms;
}
.group:hover .sidebar-soon-badge { opacity: 1; }

.sidebar-badge {
    font-size: 0.625rem;
    font-weight: 600;
    padding: 0.0625rem 0.375rem;
    border-radius: 9999px;
}

.sidebar-section-btn[aria-expanded="true"] .chevron-icon,
[data-menu-id][aria-expanded="true"] .chevron-icon {
    transform: rotate(180deg);
}

/* JA landing-card left-stripe: Tailwind only compiled border-l-amber-500
   (used by mano action_cards/card_list.html). border-l-brand-500 is needed
   for the own-JA flow cards in ja_v2/_entity_landing.html. One-line shim
   instead of a full Tailwind rebuild. brand-500 = #027377 per tailwind.config.js. */
.border-l-brand-500 { border-left-color: #027377; }

@media (max-width: 1023px) {
    #entity-sidebar.sidebar-mobile-open {
        display: flex !important;
        position: fixed;
        top: 4rem;
        left: 0;
        bottom: 0;
        z-index: 30;
        box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    }
}

/* ── Language menu (localization G1) ─────────────────────────────────────
   The one language control on every web surface: public header, Sign shell,
   guest ceremony. Fixed width whatever the number of languages, which is the
   point - the one-control-per-language row it replaces grew with each added
   language. Dark-theme overrides for the Sign shell live in sign-product.css
   alongside the other data-sign-theme rules. */
.tv-lang { position: relative; display: inline-block; }
.tv-lang > summary {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #4b5563;
    cursor: pointer;
    list-style: none;
    user-select: none;
}
.tv-lang > summary::-webkit-details-marker { display: none; }
.tv-lang > summary:hover { color: #111827; background: #f3f4f6; }
.tv-lang > summary:focus-visible { outline: 2px solid #0E4751; outline-offset: 2px; }
.tv-lang-globe { width: 1.125rem; height: 1.125rem; flex-shrink: 0; }
.tv-lang-code { letter-spacing: 0.02em; }
.tv-lang-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 0.25rem);
    z-index: 50;
    min-width: 11rem;
    padding: 0.375rem;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 0.625rem;
    box-shadow: 0 10px 25px -5px rgb(0 0 0 / 0.15);
}
.tv-lang-heading {
    margin: 0;
    padding: 0.25rem 0.625rem 0.375rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9ca3af;
}
.tv-lang-panel form { display: contents; }
.tv-lang-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
    padding: 0.5rem 0.625rem;
    border: 0;
    border-radius: 0.375rem;
    background: none;
    font-size: 0.875rem;
    font-family: inherit;
    color: #374151;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}
.tv-lang-item:hover { background: #f3f4f6; color: #111827; }
.tv-lang-item.is-current { font-weight: 600; color: #0E4751; }
.tv-lang-item.is-current::after { content: "✓"; }
/* tvarka.pro's language menu: the second group offering tvarka.eu (tvarka_eu.market). */
.tv-lang-cross { margin-top: 0.375rem; padding-top: 0.375rem; border-top: 1px solid #e5e7eb; }
.tv-lang-cross-link {
    display: block;
    padding: 0.5rem 0.625rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #0E4751;
    text-decoration: none;
}
.tv-lang-cross-link:hover { background: #f3f4f6; color: #0E4751; }
@media (min-width: 640px) { .tv-lang-cross-link { min-width: 15rem; } }

/* The banner offering the other Tvarka site (both hosts): one sentence, one
   button and a close link, which the server remembers (no script). */
.tv-market-banner {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem 1rem;
    padding: 0.625rem 3rem 0.625rem 1rem;
    background: #0E4751;
    color: #ffffff;
    font-size: 0.875rem;
    line-height: 1.4;
    text-align: center;
}
.tv-market-banner-text { margin: 0; }
.tv-market-banner-go {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.85rem;
    border-radius: 9999px;
    background: #ffffff;
    color: #0E4751;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}
.tv-market-banner-go:hover { background: #e6f0f1; color: #0E4751; }
.tv-market-banner-close {
    position: absolute;
    top: 50%;
    right: 0.75rem;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    color: #ffffff;
    font-size: 1.25rem;
    line-height: 1;
    text-decoration: none;
}
.tv-market-banner-close:hover { background: rgb(255 255 255 / 0.15); color: #ffffff; }
.tv-market-banner a:focus-visible { outline: 2px solid #ffffff; outline-offset: 2px; }

/* Trust marks row: marketing/includes/_trust_marks.html (2026-10-10) */
.trust-marks {
    --tm-accent: #00A291;
    --tm-knock: #FFFFFF;
    color: #3F4D4B;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 18px 40px;
    margin: 44px auto 0;
}
.trust-marks-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 18px 40px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.trust-mark {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 1;
    text-transform: uppercase;
    white-space: nowrap;
    opacity: 0.85;
}
.trust-mark svg { display: block; height: 30px; width: auto; flex: none; }
.trust-mark .tm-a { stroke: var(--tm-accent); }
.trust-mark .tm-ks { stroke: var(--tm-knock); }
.trust-mark .tm-kf { fill: var(--tm-knock); }
.trust-marks-link {
    font-size: 15px;
    font-weight: 600;
    color: #027377;
    text-decoration: none;
    white-space: nowrap;
}
.trust-marks-link:hover { text-decoration: underline; }
.trust-marks--page,
.trust-marks--page .trust-marks-list { justify-content: flex-start; }
.trust-marks--page { margin: 4px 0 32px; }
.trust-marks--page .trust-marks-list { gap: 16px 30px; }
.trust-marks--page .trust-mark { font-size: 15px; }
.trust-marks--page .trust-mark svg { height: 34px; }
@media (max-width: 640px) {
    .trust-marks,
    .trust-marks-list { gap: 16px 26px; }
    .trust-mark { font-size: 12px; }
    .trust-mark svg { height: 26px; }
    .trust-marks-link { flex-basis: 100%; text-align: center; }
    .landing-page .trust-marks { --tm-accent: #62C4A5; --tm-knock: #0B191E; color: #C5D0CE; }
    .landing-page .trust-marks-link { color: #62C4A5; }
}

/* ── One look for all products (owner ruling 10, 2026-11-12, X-13, L-4) ──
   One set of colour tokens for both frames: the Sign frame (Sign, HR, Sauga,
   Formos) and the platform frame (templates/base.html). The light values are
   the light Sign look, the dark values the dark Sign look. The theme is
   painted on <html> by {% ui_theme_head %} (accounts/templatetags/tvarka_theme.py):
   data-sign-theme and data-color-scheme always carry the same value.
   One amber primary with dark ink, one teal for secondary actions, one red
   for deletes. Every text pair below reads at 4.5:1 or more (checked
   2026-11-12): muted on page 5.2, amber ink 9.2, white on teal 6.4 (dark
   4.9), white on red 6.5 (dark 5.5). */
:root {
    --tv-page: #f8faf9;
    --tv-surface: #ffffff;
    --tv-raised: #f3f7f6;
    --tv-line: #d8e2e0;
    --tv-line-strong: #b8cbc6;
    --tv-text: #17252b;
    --tv-text-2: #40524e;
    --tv-muted: #5b6e69;
    --tv-link: #1c696a;
    --tv-focus: #00a291;
    --tv-focus-ring: rgba(0, 162, 145, 0.18);
    --tv-input: #f9fbfa;
    --tv-input-line: #d1dcd9;
    --tv-input-hover: #f8f8fb;
    --tv-input-focus: #ffffff;
    --tv-input-readonly: #eef2f1;
    --tv-primary: #f0ad4e;
    --tv-primary-hover: #e8a03c;
    --tv-primary-ink: #211500;
    --tv-secondary: #1c696a;
    --tv-secondary-hover: #15595b;
    --tv-secondary-ink: #ffffff;
    --tv-danger: #b91c1c;
    --tv-danger-hover: #991b1b;
    --tv-danger-ink: #ffffff;
    --tv-danger-soft: #fff1f2;
    --tv-danger-soft-line: #fecaca;
    --tv-danger-soft-text: #b91c1c;
    --tv-scroll-track: #f0f0f5;
    --tv-scroll-thumb: #b8b8c8;
    --tv-scroll-thumb-hover: #9494a8;
    /* The greatest width of a form on a product page (L-16). */
    --tv-form-max: 56rem;
}
html[data-sign-theme="dark"] {
    --tv-page: #0d1417;
    --tv-surface: #111b20;
    --tv-raised: #17262c;
    --tv-line: #263841;
    --tv-line-strong: #2f6f72;
    --tv-text: #edf6f3;
    --tv-text-2: #dbe8e5;
    --tv-muted: #a9bbb7;
    --tv-link: #5fd3c4;
    --tv-focus: #3dbdad;
    --tv-focus-ring: rgba(61, 189, 173, 0.25);
    --tv-input: #0f181d;
    --tv-input-line: #2b414a;
    --tv-input-hover: #121f25;
    --tv-input-focus: #121f25;
    --tv-input-readonly: #0f181d;
    --tv-primary: #f0ad4e;
    --tv-primary-hover: #f5c882;
    --tv-primary-ink: #211500;
    --tv-secondary: #237d7d;
    --tv-secondary-hover: #1c696a;
    --tv-secondary-ink: #ffffff;
    --tv-danger: #c53030;
    --tv-danger-hover: #a82828;
    --tv-danger-ink: #ffffff;
    --tv-danger-soft: #32191c;
    --tv-danger-soft-line: #72343b;
    --tv-danger-soft-text: #f4a2ae;
    --tv-scroll-track: #111b20;
    --tv-scroll-thumb: #2f4650;
    --tv-scroll-thumb-hover: #3e5a65;
}
:root { scrollbar-color: var(--tv-scroll-thumb) var(--tv-scroll-track); }

/* ── The shared form look (L-16) ──
   One class set and one greatest width for the forms of every product page,
   in both themes. A page puts .tv-form on its form or section; fields are
   .tv-field with .tv-label, .tv-input and .tv-hint; choices are .tv-choice;
   the buttons are .tv-btn with -primary (amber), -secondary (teal), -danger
   (red) or -quiet. .tv-form-page caps a page of forms at --tv-form-max. */
.tv-form-page,
.tv-page-narrow { max-width: var(--tv-form-max); }
/* The settings page (owner 2026-11-12: too much scrolling). The cards stand
   in two columns where the page is wide enough, so nearly the whole page is
   seen at once on a desktop. The cards keep their order: down the first
   column, then down the second. "Išsaugoti" stands beside the page title as
   well, so a change is saved without scrolling to the end. */
.tv-settings,
.tv-settings-head { max-width: 76rem; }
.tv-settings-cards {
    columns: 2 26rem;
    column-gap: 1.25rem;
}
.tv-settings-cards > * {
    margin: 0 0 1.25rem;
    break-inside: avoid;
}
.tv-settings-cards > .tv-note { margin-bottom: 1.25rem; }
.tv-settings-cards > .tv-span-all { column-span: all; }
/* A choice among a few: tiles with an icon in one row. The hint of the
   chosen tile is shown under the row, so three choices take one line where
   they took three boxes. The radio button itself is kept for the keyboard
   and for screen readers, out of sight. */
.tv-tiles {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
}
.tv-tiles-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tv-tile { display: contents; cursor: pointer; }
.tv-tile > input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
    pointer-events: none;
}
.tv-tile-box {
    grid-row: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 2.75rem;
    border: 1px solid var(--tv-line);
    border-radius: 0.5rem;
    background: var(--tv-surface);
    color: var(--tv-muted);
    padding: 0.5rem 0.625rem;
    text-align: center;
}
.tv-tile-box .tv-icon { flex-shrink: 0; width: 1.25rem; height: 1.25rem; }
.tv-tile:hover .tv-tile-box { border-color: var(--tv-line-strong); background: var(--tv-raised); }
.tv-tile:has(input:checked) .tv-tile-box {
    border-color: var(--tv-secondary);
    box-shadow: inset 0 0 0 1px var(--tv-secondary);
    color: var(--tv-link);
}
.tv-tile:has(input:focus-visible) .tv-tile-box {
    border-color: var(--tv-focus);
    box-shadow: 0 0 0 3px var(--tv-focus-ring);
}
.tv-tile-hint {
    grid-row: 2;
    grid-column: 1 / -1;
    display: none;
}
.tv-tile:has(input:checked) .tv-tile-hint { display: block; }
.tv-card {
    border: 1px solid var(--tv-line);
    border-radius: 0.5rem;
    background: var(--tv-surface);
    color: var(--tv-text-2);
    padding: 1.25rem;
}
.tv-card-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    color: var(--tv-text);
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.4;
}
/* A section title carries its icon. */
.tv-card-title .tv-icon {
    flex-shrink: 0;
    width: 1.125rem;
    height: 1.125rem;
    color: var(--tv-muted);
}
.tv-card-sub {
    margin: 0.25rem 0 0;
    color: var(--tv-muted);
    font-size: 0.875rem;
}
.tv-card-title + .tv-form-grid,
.tv-card-sub + .tv-form-grid,
.tv-card-title + .tv-choices,
.tv-card-title + input[type="hidden"] + .tv-choices { margin-top: 1rem; }
.tv-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
}
@media (min-width: 1024px) {
    .tv-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.tv-field {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}
.tv-field-wide { grid-column: 1 / -1; }
.tv-label {
    padding: 0;
    color: var(--tv-text-2);
    font-size: 0.875rem;
    font-weight: 600;
}
.tv-hint {
    margin: 0;
    color: var(--tv-muted);
    font-size: 0.75rem;
    line-height: 1.45;
}
.tv-muted { color: var(--tv-muted); }
.tv-input,
.tv-form input:where([type="text"], [type="email"], [type="password"], [type="number"], [type="date"], [type="tel"], [type="url"], [type="search"], :not([type])),
.tv-form select,
.tv-form textarea {
    width: 100%;
    min-height: 2.5rem;
    border: 1px solid var(--tv-input-line);
    border-radius: 0.5rem;
    background-color: var(--tv-input);
    color: var(--tv-text);
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.4;
}
.tv-input:hover,
.tv-form select:hover,
.tv-form textarea:hover { border-color: var(--tv-line-strong); background-color: var(--tv-input-hover); }
.tv-input:focus,
.tv-form input:focus,
.tv-form select:focus,
.tv-form textarea:focus {
    outline: none;
    border-color: var(--tv-focus);
    background-color: var(--tv-input-focus);
    box-shadow: 0 0 0 3px var(--tv-focus-ring);
}
.tv-input[readonly],
.tv-input:disabled {
    background-color: var(--tv-input-readonly);
    color: var(--tv-muted);
    box-shadow: none;
}
.tv-input::placeholder { color: var(--tv-muted); opacity: 0.85; }
.tv-form input[type="file"] { color: var(--tv-text-2); font-size: 0.875rem; }
.tv-form input[type="file"]::file-selector-button {
    margin-right: 0.75rem;
    border: 1px solid var(--tv-line);
    border-radius: 0.5rem;
    background: var(--tv-raised);
    color: var(--tv-text);
    padding: 0.5rem 0.875rem;
    font-weight: 600;
    cursor: pointer;
}
.tv-choices { display: grid; gap: 0.5rem; }
.tv-choices-row { display: flex; flex-wrap: wrap; }
.tv-choice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    border: 1px solid var(--tv-line);
    border-radius: 0.5rem;
    background: var(--tv-surface);
    padding: 0.625rem 0.75rem;
    cursor: pointer;
}
.tv-choice:hover { border-color: var(--tv-line-strong); background: var(--tv-raised); }
/* The chosen one of several is outlined. A ticked box is not: its tick says enough, and a list of outlined boxes was heavy to read. */
.tv-choice:has(input[type="radio"]:checked) { border-color: var(--tv-secondary); box-shadow: inset 0 0 0 1px var(--tv-secondary); }
.tv-choice input { flex-shrink: 0; margin-top: 0.2rem; accent-color: var(--tv-secondary); }
.tv-choice > span { display: flex; flex-direction: column; gap: 0.125rem; min-width: 0; }
.tv-choice-label { color: var(--tv-text); font-size: 0.875rem; font-weight: 600; }
.tv-note {
    margin: 0;
    border: 1px dashed var(--tv-line-strong);
    border-radius: 0.5rem;
    color: var(--tv-muted);
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
}
.tv-form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
}
.tv-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 2.5rem;
    border: 1px solid transparent;
    border-radius: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}
.tv-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--tv-focus-ring); }
.tv-btn-primary { border-color: var(--tv-primary); background: var(--tv-primary); color: var(--tv-primary-ink); }
.tv-btn-primary:hover { border-color: var(--tv-primary-hover); background: var(--tv-primary-hover); color: var(--tv-primary-ink); }
.tv-btn-secondary { border-color: var(--tv-secondary); background: var(--tv-secondary); color: var(--tv-secondary-ink); }
.tv-btn-secondary:hover { border-color: var(--tv-secondary-hover); background: var(--tv-secondary-hover); color: var(--tv-secondary-ink); }
.tv-btn-danger { border-color: var(--tv-danger); background: var(--tv-danger); color: var(--tv-danger-ink); }
.tv-btn-danger:hover { border-color: var(--tv-danger-hover); background: var(--tv-danger-hover); color: var(--tv-danger-ink); }
.tv-btn-quiet { border-color: var(--tv-line); background: transparent; color: var(--tv-text-2); }
.tv-btn-quiet:hover { background: var(--tv-raised); color: var(--tv-text); }

/* Amber with white ink reads at 2.2:1. Every amber button carries the dark
   ink, in both frames and both themes (L-8, ruling 10). */
.bg-amber-500.text-white,
.bg-amber-600.text-white,
.hover\:bg-amber-600:hover.text-white,
.btn-accent { color: var(--tv-primary-ink) !important; }
.btn-accent { background-color: var(--tv-primary); }
.btn-accent:hover { background-color: var(--tv-primary-hover); }

/* The platform frame (templates/base.html): its main button is the one
   amber with dark ink, its quiet grey text reads at 4.5:1. The public site
   keeps its own look. */
.app-body .btn-primary { background-color: var(--tv-primary); color: var(--tv-primary-ink); }
.app-body .btn-primary:hover { background-color: var(--tv-primary-hover); color: var(--tv-primary-ink); box-shadow: 0 4px 12px rgba(240, 173, 78, 0.3); }
.app-body .text-gray-400 { color: #6b7280; }
.tv-theme-toggle .tv-theme-icon-sun { display: none; }
html[data-sign-theme="dark"] .tv-theme-toggle .tv-theme-icon-sun { display: block; }
html[data-sign-theme="dark"] .tv-theme-toggle .tv-theme-icon-moon { display: none; }

/* Quiet text of the platform frame reads at 4.5:1 or more (UX gate 2026-11-12). */
.tv-kbd { color: var(--tv-muted) !important; background-color: var(--tv-raised) !important; border-color: var(--tv-line) !important; }
:root:not([data-color-scheme="dark"]) .app-body .pp-rows-title { color: #555d69; }

/* The header of the platform frame fits a 375 px phone (UX gate 2026-11-12):
   a smaller logo and gaps; the search, help and gear buttons wait for a wider
   screen. The settings are in the profile menu as well. */
@media (max-width: 639px) {
    .app-body .nav-brand > div { padding-left: 0.75rem; padding-right: 0.75rem; }
    .app-body .nav-brand .h-16 { gap: 0.5rem; }
    .app-body .nav-brand .app-logo { height: 2rem; }
    .app-body .nav-brand .h-16 > .min-w-0.flex-1 { display: none; }
    .app-body .nav-brand .h-16 > :last-child { margin-left: auto; }
    .app-body .nav-brand .ml-6 { margin-left: 0.5rem; }
    .tv-hide-mobile { display: none !important; }
}
