/* ============================================================
   RDY.cz — Graphite Lime Design System
   Verze: 6.0
   ============================================================ */

/* --- Theme: light (Graphite Lime) --- */
html[data-theme="light"], :root {
    --bg: #f5f4ee;
    --surface: #fbfaf6;
    --surface-2: #ecebe3;
    --surface-strong: #f5f4ee;
    --fg: #15170f;
    --muted: #6a6c5e;
    --border: #d8d6c8;

    --accent: #b8d23a;
    --accent-on: #15170f;
    --accent-hover: #a6bf2a;
    --accent-soft: #e7eecb;
    --accent-soft-border: #cdd896;

    --accent-2: #15170f;
    --accent-2-on: #b8d23a;
    --accent-3: #6a6c5e;
    --accent-3-on: #fbfaf6;

    --marquee-bg: #15170f;
    --marquee-fg: #b8d23a;
    --phone-bg: #ecebe3;

    --success: #4a7c2e;
    --success-bg: #e7eecb;
    --danger: #b3261e;
    --danger-bg: #f9d7d4;
    --warning: #b8860b;
    --warning-bg: #fdf3d3;
    --info: #2563b3;
    --info-bg: #d6e6f7;

    --shadow-sm: 0 1px 0 rgba(0,0,0,0.04);
    --shadow-md: 0 4px 12px rgba(21,23,15,0.06);
    --shadow-lg: 0 24px 60px -20px rgba(21,23,15,0.18);
}

/* --- Theme: dark --- */
html[data-theme="dark"] {
    --bg: #0e0f08;
    --surface: #16170f;
    --surface-2: #1f2117;
    --surface-strong: #0e0f08;
    --fg: #f5f4ee;
    --muted: #8c8d7e;
    --border: #2a2c20;

    --accent: #c8e04a;
    --accent-on: #15170f;
    --accent-hover: #d6ee5a;
    --accent-soft: #2a3210;
    --accent-soft-border: #3f4a1c;

    --accent-2: #f5f4ee;
    --accent-2-on: #15170f;
    --accent-3: #8c8d7e;
    --accent-3-on: #0e0f08;

    --marquee-bg: #c8e04a;
    --marquee-fg: #15170f;
    --phone-bg: #1f2117;

    --success: #9bcf6e;
    --success-bg: #2a3a1c;
    --danger: #ef9a9a;
    --danger-bg: #3a1c1c;
    --warning: #f4d76b;
    --warning-bg: #3a2f10;
    --info: #8ab4f0;
    --info-bg: #1c2a3a;

    --shadow-sm: 0 1px 0 rgba(0,0,0,0.4);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
    --shadow-lg: 0 24px 60px -20px rgba(0,0,0,0.6);
}

/* --- Tokens --- */
:root {
    --maxw: 1180px;
    --pad: 56px;
    --pad-sm: 24px;
    --radius: 18px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --radius-lg: 28px;
    --radius-pill: 999px;
    --font-sans: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
    --font-display: 'Geist', sans-serif;
    --font-serif: 'Instrument Serif', Georgia, serif;

    --tr-fast: .12s ease;
    --tr: .18s ease;
    --tr-slow: .35s ease;
}

/* --- Reset / base --- */
* { box-sizing: border-box; }
*::before, *::after { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--fg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-feature-settings: "ss01", "cv11";
    line-height: 1.55;
    transition: background-color var(--tr-slow), color var(--tr-slow);
}
img, svg, video { max-width: 100%; height: auto; display: block; }
button { font: inherit; color: inherit; }
a { color: inherit; }
hr { border: 0; border-top: 1px solid var(--border); margin: 24px 0; }

/* --- Layout --- */
.container {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 var(--pad);
}
.container-narrow {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 var(--pad);
}
.container-wide {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--pad);
}

@media (max-width: 768px) {
    .container, .container-narrow, .container-wide { padding: 0 var(--pad-sm); }
    :root { --pad: 24px; }
}

section { padding: 100px 0; position: relative; }
section.tight { padding: 60px 0; }
section.compact { padding: 40px 0; }

@media (max-width: 768px) {
    section { padding: 64px 0; }
    section.tight { padding: 40px 0; }
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    margin: 0;
    letter-spacing: -0.025em;
    line-height: 1.05;
    font-weight: 600;
    color: var(--fg);
}
h1 { font-size: clamp(40px, 7.5vw, 96px); font-weight: 600; line-height: 1; }
h2 { font-size: clamp(32px, 4.5vw, 56px); }
h3 { font-size: clamp(20px, 2vw, 28px); line-height: 1.2; letter-spacing: -0.02em; }
h4 { font-size: 18px; line-height: 1.3; }
h5 { font-size: 15px; line-height: 1.3; font-weight: 600; }
h6 { font-size: 13px; line-height: 1.3; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }

/* Tailwind text-utility kompatibilita (admin legacy stránky) — vyšší specificita než h1 */
h1.text-xs, h2.text-xs, h3.text-xs, h4.text-xs, h5.text-xs, h6.text-xs { font-size: 0.75rem; line-height: 1rem; letter-spacing: 0; }
h1.text-sm, h2.text-sm, h3.text-sm, h4.text-sm, h5.text-sm, h6.text-sm { font-size: 0.875rem; line-height: 1.25rem; letter-spacing: 0; }
h1.text-base, h2.text-base, h3.text-base, h4.text-base, h5.text-base, h6.text-base { font-size: 1rem; line-height: 1.5rem; letter-spacing: 0; }
h1.text-lg, h2.text-lg, h3.text-lg, h4.text-lg, h5.text-lg, h6.text-lg { font-size: 1.125rem; line-height: 1.75rem; letter-spacing: 0; }
h1.text-xl, h2.text-xl, h3.text-xl, h4.text-xl, h5.text-xl, h6.text-xl { font-size: 1.25rem; line-height: 1.75rem; letter-spacing: -0.01em; }
h1.text-2xl, h2.text-2xl, h3.text-2xl, h4.text-2xl, h5.text-2xl, h6.text-2xl { font-size: 1.5rem; line-height: 2rem; letter-spacing: -0.01em; }
h1.text-3xl, h2.text-3xl, h3.text-3xl, h4.text-3xl, h5.text-3xl, h6.text-3xl { font-size: 1.875rem; line-height: 2.25rem; letter-spacing: -0.02em; }
h1.text-4xl, h2.text-4xl, h3.text-4xl, h4.text-4xl, h5.text-4xl, h6.text-4xl { font-size: 2.25rem; line-height: 2.5rem; letter-spacing: -0.02em; }
h1.text-5xl, h2.text-5xl, h3.text-5xl, h4.text-5xl, h5.text-5xl, h6.text-5xl { font-size: 3rem; line-height: 1; letter-spacing: -0.025em; }
h1.text-6xl, h2.text-6xl, h3.text-6xl, h4.text-6xl, h5.text-6xl, h6.text-6xl { font-size: 3.75rem; line-height: 1; letter-spacing: -0.025em; }

p { margin: 0; line-height: 1.55; color: var(--muted); }
.lead { font-size: 19px; line-height: 1.5; color: var(--fg); }
.muted { color: var(--muted); }
.serif { font-family: var(--font-serif); font-style: italic; font-weight: 400; }

.eyebrow {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 18px;
    display: inline-block;
}

.text-mono { font-family: var(--font-mono); }
.text-accent { color: var(--accent); }
.text-fg { color: var(--fg); }
.text-muted { color: var(--muted); }

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 22px;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: -0.01em;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform var(--tr-fast), background var(--tr), color var(--tr), border-color var(--tr);
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn.disabled { opacity: 0.55; cursor: not-allowed; }

.btn-primary { background: var(--accent); color: var(--accent-on); }
.btn-primary:hover { background: var(--accent-hover); color: var(--accent-on); }

.btn-ghost {
    background: transparent;
    color: var(--fg);
    border-color: var(--border);
}
.btn-ghost:hover { background: var(--surface-2); color: var(--fg); }

.btn-dark {
    background: var(--accent-2);
    color: var(--accent-2-on);
}
.btn-dark:hover { background: var(--fg); opacity: 0.9; }

.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { opacity: 0.9; color: white; }

.btn-sm { padding: 9px 16px; font-size: 13px; }
.btn-lg { padding: 18px 30px; font-size: 16px; }
.btn-icon { padding: 10px; width: 38px; height: 38px; gap: 0; }
.btn-block { width: 100%; }

.btn-mono {
    font-family: var(--font-mono);
    font-weight: 500;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* --- Tag / pill --- */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    background: var(--surface-2);
    color: var(--muted);
    border: 1px solid var(--border);
    line-height: 1;
}
.tag.tag-ghost { background: transparent; }
.tag.tag-accent { background: var(--accent); color: var(--accent-on); border-color: transparent; }
.tag.tag-dark { background: var(--accent-2); color: var(--accent-2-on); border-color: transparent; }
.tag .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--accent) 25%, transparent);
}
.tag.tag-dark .dot, .tag.tag-accent .dot { background: currentColor; box-shadow: none; }

.badge,
a.badge,
.rdy-prose a.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: var(--radius-pill);
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: var(--accent);
    color: var(--accent-on);
    border-bottom: 0;
    text-decoration: none;
}
.badge.badge-dark,
a.badge.badge-dark,
.rdy-prose a.badge.badge-dark { background: var(--accent-2); color: var(--accent-2-on); }
.badge.badge-soft,
a.badge.badge-soft,
.rdy-prose a.badge.badge-soft { background: var(--accent-soft); color: var(--accent); }
.rdy-prose a.badge:hover { background: var(--accent-hover); color: var(--accent-on); opacity: 1; }

/* --- Card --- */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: border-color var(--tr), background-color var(--tr), transform var(--tr);
}
.card.card-hover:hover {
    border-color: var(--accent-soft-border);
    transform: translateY(-2px);
}
.card-sm { padding: 20px; border-radius: var(--radius); }
.card-flat { background: var(--surface-2); border: 1px solid var(--border); }

/* --- Forms --- */
.input, input[type="text"], input[type="email"], input[type="password"],
input[type="url"], input[type="search"], input[type="number"], input[type="tel"],
input[type="date"], input[type="time"], textarea, select {
    width: 100%;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--fg);
    font-family: inherit;
    font-size: 15px;
    line-height: 1.4;
    outline: none;
    transition: border-color var(--tr), background var(--tr), box-shadow var(--tr);
    -webkit-appearance: none;
    appearance: none;
}
textarea { resize: vertical; min-height: 96px; }
.input:focus, input:focus, textarea:focus, select:focus {
    border-color: var(--fg);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--accent) 30%, transparent);
}
.input::placeholder, input::placeholder, textarea::placeholder { color: var(--muted); opacity: 0.6; }
.input.input-mono, input.input-mono, textarea.input-mono { font-family: var(--font-mono); font-size: 14px; }
.input.input-lg, input.input-lg { padding: 18px; font-size: 16px; }

select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3e%3cpath d='M1 1.5l5 5 5-5' stroke='%2315170f' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}
html[data-theme="dark"] select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3e%3cpath d='M1 1.5l5 5 5-5' stroke='%23f5f4ee' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
}

.input-group {
    display: flex;
    align-items: stretch;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg);
    overflow: hidden;
}
.input-group:focus-within {
    border-color: var(--fg);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--accent) 30%, transparent);
}
.input-group > .input-group-prefix,
.input-group > .input-group-suffix {
    padding: 14px 16px;
    background: var(--surface-2);
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: 13px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.input-group > .input-group-prefix { border-right: 1px solid var(--border); }
.input-group > .input-group-suffix { border-left: 1px solid var(--border); }
.input-group > input, .input-group > select, .input-group > textarea {
    border: 0; border-radius: 0; flex: 1; box-shadow: none;
    background: transparent;
}
.input-group > input:focus { box-shadow: none; }

label, .label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    margin-bottom: 8px;
}
.field { margin-bottom: 16px; }
.field-help { display: block; font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.field-error { color: var(--danger); font-size: 13px; margin-top: 6px; }

input[type="checkbox"], input[type="radio"] {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border: 1.5px solid var(--border);
    background: var(--bg);
    border-radius: 5px;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: background var(--tr), border-color var(--tr);
}
input[type="radio"] { border-radius: 50%; }
input[type="checkbox"]:checked, input[type="radio"]:checked {
    background: var(--accent);
    border-color: var(--accent);
}
input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3e%3cpath d='M3 8l3 3 7-7' stroke='%2315170f' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e") center/12px no-repeat;
}
input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    inset: 4px;
    background: var(--accent-on);
    border-radius: 50%;
}
.checkbox-label { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; font-size: 14px; color: var(--fg); }

/* --- Switch (toggle) --- */
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch-track {
    width: 36px; height: 20px; border-radius: var(--radius-pill);
    background: var(--surface-2); border: 1px solid var(--border);
    position: relative; transition: background var(--tr), border-color var(--tr);
}
.switch-track::after {
    content: '';
    position: absolute; top: 1px; left: 1px;
    width: 16px; height: 16px; border-radius: 50%;
    background: var(--fg);
    transition: left var(--tr), background var(--tr);
}
.switch input:checked + .switch-track { background: var(--accent); border-color: var(--accent); }
.switch input:checked + .switch-track::after { left: 17px; background: var(--accent-on); }

/* --- Tabs --- */
.tabs {
    display: inline-flex;
    gap: 6px;
    padding: 6px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
}
.tabs .tab {
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    border: 0;
    cursor: pointer;
    background: transparent;
    color: var(--muted);
    font-size: 14px;
    font-weight: 600;
    transition: all var(--tr);
    text-decoration: none;
    line-height: 1;
}
.tabs .tab.active, .tabs .tab[aria-selected="true"] {
    background: var(--surface);
    color: var(--fg);
    box-shadow: var(--shadow-sm), 0 0 0 1px var(--border);
}
@media (max-width: 640px) {
    .tabs { width: 100%; overflow-x: auto; flex-wrap: nowrap; }
    .tabs .tab { white-space: nowrap; padding: 8px 14px; font-size: 13px; }
}

/* --- Header --- */
.rdy-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: color-mix(in oklch, var(--bg) 86%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
}
.rdy-header .header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
    gap: 16px;
}
.rdy-logo {
    display: flex;
    align-items: baseline;
    gap: 2px;
    text-decoration: none;
    color: var(--fg);
    flex-shrink: 0;
}
.rdy-logo .logo-name { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.04em; }
.rdy-logo .logo-tld { font-family: var(--font-mono); font-size: 13px; color: var(--accent); font-weight: 600; }

.rdy-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}
.rdy-nav a {
    padding: 8px 14px;
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 500;
    color: var(--fg);
    text-decoration: none;
    opacity: 0.8;
    transition: opacity var(--tr), background var(--tr);
}
.rdy-nav a:hover, .rdy-nav a.active { opacity: 1; background: var(--surface-2); }

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

.theme-toggle {
    width: 38px;
    height: 38px;
    border-radius: 999px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    cursor: pointer;
    display: grid;
    place-items: center;
    color: var(--fg);
    transition: background var(--tr);
}
.theme-toggle:hover { background: var(--surface); }
.theme-toggle .icon-sun { display: none; }
html[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

.mobile-menu-toggle {
    display: none;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    cursor: pointer;
    place-items: center;
    color: var(--fg);
}
@media (max-width: 1024px) {
    .rdy-nav { display: none; }
    .mobile-menu-toggle { display: grid; }
}
@media (max-width: 640px) {
    .rdy-header-actions .btn-text-mobile-hide { display: none; }
    .rdy-header .header-inner { height: 60px; }
}

/* --- Mobile drawer --- */
.mobile-drawer {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: color-mix(in oklch, var(--bg) 96%, transparent);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: none;
    flex-direction: column;
    padding: 24px;
    overflow-y: auto;
}
.mobile-drawer.open { display: flex; }
.mobile-drawer .drawer-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}
.mobile-drawer nav { display: flex; flex-direction: column; gap: 4px; }
.mobile-drawer nav a {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    font-size: 18px;
    font-weight: 500;
    color: var(--fg);
    text-decoration: none;
    border: 1px solid transparent;
}
.mobile-drawer nav a:hover { background: var(--surface-2); border-color: var(--border); }
.mobile-drawer .drawer-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }

/* --- Dropdown --- */
.dropdown { position: relative; display: inline-block; }
.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 220px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    padding: 6px;
    display: none;
    z-index: 60;
}
.dropdown.open .dropdown-menu { display: block; }
.dropdown-menu a, .dropdown-menu button {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    border: 0;
    background: transparent;
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--fg);
    text-decoration: none;
    cursor: pointer;
    text-align: left;
}
.dropdown-menu a:hover, .dropdown-menu button:hover { background: var(--surface-2); }
.dropdown-divider { height: 1px; background: var(--border); margin: 6px 0; }

/* --- Marquee --- */
.marquee {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    background: var(--marquee-bg);
}
.marquee-track {
    display: flex;
    gap: 56px;
    padding: 20px 0;
    white-space: nowrap;
    animation: rdy-marquee 30s linear infinite;
}
.marquee-track > span {
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 500;
    color: var(--marquee-fg);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    display: inline-flex;
    align-items: center;
    gap: 56px;
}
@keyframes rdy-marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* --- Reveal on scroll --- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .7s ease, transform .7s ease;
}
.reveal.in { opacity: 1; transform: none; }

/* --- Counter (tabular nums) --- */
.counter-num {
    font-family: var(--font-mono);
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

/* --- Tables --- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-md); border: 1px solid var(--border); background: var(--surface); }
table.rdy-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
table.rdy-table th, table.rdy-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
table.rdy-table th {
    font-family: var(--font-mono);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    font-weight: 600;
    background: var(--surface-2);
}
table.rdy-table tr:last-child td { border-bottom: 0; }
table.rdy-table tr:hover td { background: var(--surface-2); }
table.rdy-table .col-mono { font-family: var(--font-mono); font-weight: 500; }
table.rdy-table .col-num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; text-align: right; }

/* --- Alerts / toasts --- */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--surface);
    font-size: 14px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.alert-success { background: var(--success-bg); border-color: color-mix(in oklch, var(--success) 35%, transparent); color: var(--success); }
.alert-danger  { background: var(--danger-bg);  border-color: color-mix(in oklch, var(--danger) 35%, transparent);  color: var(--danger); }
.alert-warning { background: var(--warning-bg); border-color: color-mix(in oklch, var(--warning) 35%, transparent); color: var(--warning); }
.alert-info    { background: var(--info-bg);    border-color: color-mix(in oklch, var(--info) 35%, transparent);    color: var(--info); }
.alert strong { color: inherit; }

/* --- Toast (flash) --- */
.toast {
    position: fixed;
    top: 84px;
    right: 16px;
    z-index: 200;
    max-width: 380px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: toast-in .35s cubic-bezier(.2,.8,.2,1);
}
.toast.toast-success { border-color: var(--success); background: var(--success-bg); color: var(--success); }
.toast.toast-danger  { border-color: var(--danger);  background: var(--danger-bg);  color: var(--danger); }
.toast.toast-warning { border-color: var(--warning); background: var(--warning-bg); color: var(--warning); }
.toast.toast-info    { border-color: var(--info);    background: var(--info-bg);    color: var(--info); }
.toast .toast-close { margin-left: auto; opacity: 0.6; cursor: pointer; background: transparent; border: 0; padding: 4px; color: inherit; }
.toast .toast-close:hover { opacity: 1; }
@keyframes toast-in { from { transform: translateX(120%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes toast-out { from { transform: translateX(0); opacity: 1; } to { transform: translateX(120%); opacity: 0; } }
.toast.closing { animation: toast-out .3s ease forwards; }

/* --- Footer --- */
.rdy-footer {
    border-top: 1px solid var(--border);
    padding: 64px 0 36px;
    background: var(--bg);
    margin-top: auto;
}
.rdy-footer .footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 36px;
    margin-bottom: 48px;
}
.rdy-footer .footer-col h6 {
    font-family: var(--font-mono);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
    margin-bottom: 14px;
    font-weight: 600;
}
.rdy-footer .footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.rdy-footer .footer-col a { font-size: 14px; color: var(--fg); opacity: 0.85; text-decoration: none; }
.rdy-footer .footer-col a:hover { opacity: 1; }
.rdy-footer .footer-bottom {
    padding-top: 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}
.rdy-footer .footer-bottom p { font-size: 12.5px; color: var(--muted); margin: 0; }
.rdy-footer .footer-bottom a { color: var(--muted); text-decoration: none; font-size: 12.5px; }
.rdy-footer .footer-bottom a:hover { color: var(--fg); }
.rdy-footer .footer-social { display: flex; gap: 10px; }
.rdy-footer .footer-social a {
    width: 38px; height: 38px; border-radius: 50%;
    background: var(--surface-2); border: 1px solid var(--border);
    display: grid; place-items: center; color: var(--fg);
    transition: background var(--tr), color var(--tr);
}
.rdy-footer .footer-social a:hover { background: var(--accent); color: var(--accent-on); border-color: transparent; }

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

/* --- Prose (legal pages, blog articles) --- */
.rdy-prose {
    max-width: 760px;
    margin: 0 auto;
    color: var(--fg);
    font-size: 16px;
    line-height: 1.7;
}
.rdy-prose h1, .rdy-prose h2, .rdy-prose h3, .rdy-prose h4 {
    margin-top: 36px;
    margin-bottom: 14px;
    line-height: 1.2;
}
.rdy-prose h1 { font-size: clamp(32px, 4vw, 44px); margin-top: 0; }
.rdy-prose h2 { font-size: clamp(22px, 2.5vw, 28px); padding-top: 6px; }
.rdy-prose h3 { font-size: 19px; }
.rdy-prose h4 { font-size: 16px; }
.rdy-prose p { color: var(--fg); margin: 14px 0; }
.rdy-prose ul, .rdy-prose ol { margin: 14px 0; padding-left: 24px; }
.rdy-prose li { margin: 6px 0; color: var(--fg); }
.rdy-prose li::marker { color: var(--accent); }
.rdy-prose a { color: var(--accent); text-decoration: none; border-bottom: 1.5px solid var(--accent); }
.rdy-prose a:hover { background: var(--accent-soft); }
.rdy-prose a.badge { color: var(--accent-on); border-bottom: 0; }
.rdy-prose a.badge:hover { background: var(--accent); opacity: 0.85; }
.rdy-prose strong { color: var(--fg); }
.rdy-prose code { font-family: var(--font-mono); font-size: 0.9em; padding: 2px 6px; background: var(--surface-2); border-radius: 4px; }
.rdy-prose blockquote { border-left: 3px solid var(--accent); padding: 4px 16px; margin: 18px 0; color: var(--muted); font-style: italic; }
.rdy-prose hr { margin: 28px 0; border-color: var(--border); }
.rdy-prose .rdy-prose-callout {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 18px 22px;
    margin: 18px 0;
}
.rdy-prose img { border-radius: var(--radius-md); margin: 14px 0; }

/* --- Hero accent helpers --- */
.hero-grid-bg {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 48px 48px;
    opacity: 0.4;
    mask-image: radial-gradient(ellipse 80% 60% at 30% 30%, black 30%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 30% 30%, black 30%, transparent 70%);
    pointer-events: none;
}

/* --- Sortable.js helpers --- */
.sortable-ghost { opacity: 0.4; }
.sortable-chosen { background: var(--accent-soft); }
.sortable-drag { cursor: grabbing; }

/* --- Utilities --- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 4px; } .gap-2 { gap: 8px; } .gap-3 { gap: 12px; } .gap-4 { gap: 16px; }
.gap-5 { gap: 20px; } .gap-6 { gap: 24px; } .gap-8 { gap: 32px; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1; }
.grid { display: grid; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.w-full { width: 100%; }
.relative { position: relative; }
.absolute { position: absolute; }
.hidden { display: none !important; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 4px; } .mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; } .mt-6 { margin-top: 24px; } .mt-8 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 4px; } .mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; } .mb-4 { margin-bottom: 16px; } .mb-6 { margin-bottom: 24px; } .mb-8 { margin-bottom: 32px; }

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .marquee-track { animation: none; }
}

/* --- Print --- */
@media print {
    .rdy-header, .rdy-footer, .marquee, .toast, .mobile-drawer { display: none !important; }
    body { background: white; color: black; }
}
