:root {
  --accent: #e82127;
  --background: #f6f7f8;
  --surface: #ffffff;
  --text: #171a20;
  --muted: #66707c;
  --line: #e4e7eb;
  --dark: #111318;
  --radius: 18px;
  --shadow: 0 18px 55px rgba(21, 26, 35, .08);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--background); color: var(--text); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.55; }
.font-classic { font-family: Georgia, "Times New Roman", serif; }
.font-classic input, .font-classic textarea, .font-classic select, .font-classic button { font-family: Inter, ui-sans-serif, system-ui, sans-serif; }
.font-technical { font-family: "Trebuchet MS", Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: .005em; }
.radius-square { --radius: 2px; }
.radius-soft { --radius: 10px; }
.width-standard .container { width: min(1000px, calc(100% - 48px)); }
.width-full .container { width: min(1440px, calc(100% - 48px)); }
.header-transparent .site-header { background: color-mix(in srgb, var(--background) 65%, transparent); }
.header-dark .site-header { background: rgba(17,19,24,.96); color: #fff; border-color: #292d33; }
.header-dark .site-header .brand small { color: #a9afb8; }
.buttons-square .button, .buttons-square .nav-cta { border-radius: 2px; }
.buttons-pill .button, .buttons-pill .nav-cta { border-radius: 999px; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.08; letter-spacing: -.035em; }
input, textarea, select { width: 100%; border: 1px solid #d9dde2; border-radius: 10px; background: #fff; color: #171a20; padding: 11px 12px; outline: 0; transition: border-color .15s, box-shadow .15s; }
textarea { resize: vertical; }
input:focus, textarea:focus, select:focus { border-color: #818995; box-shadow: 0 0 0 3px rgba(40, 50, 65, .1); }
label { display: grid; gap: 7px; color: #4c5561; font-size: 13px; font-weight: 650; }

.container { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.site-header { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; min-height: 78px; padding: 12px max(24px, calc((100vw - 1280px) / 2)); background: color-mix(in srgb, var(--background) 88%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--text) 10%, transparent); backdrop-filter: blur(16px); }
.brand { display: inline-flex; align-items: center; gap: 11px; }
.brand > span, .admin-brand > span, .login-brand > a span { display: grid; place-items: center; width: 35px; height: 35px; border-radius: 10px; background: var(--accent); color: #fff; font-weight: 850; }
.brand div { display: grid; }
.brand b { letter-spacing: -.02em; }
.brand small { color: var(--muted); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
.site-header nav { display: flex; align-items: center; gap: 7px; }
.site-header nav a { padding: 10px 13px; border-radius: 9px; font-size: 13px; font-weight: 650; }
.site-header nav a:hover { background: color-mix(in srgb, var(--text) 6%, transparent); }
.site-header nav .nav-cta { background: var(--text); color: var(--surface); }
.mobile-menu, .admin-menu { display: none; border: 0; background: transparent; cursor: pointer; font-size: 24px; }

.hero { min-height: 620px; display: grid; align-items: center; overflow: hidden; position: relative; background: radial-gradient(circle at 86% 20%, color-mix(in srgb, var(--accent) 11%, transparent), transparent 26%), linear-gradient(145deg, var(--surface), var(--background)); }
.hero::after { content: "T"; position: absolute; right: -1vw; bottom: -19vw; color: color-mix(in srgb, var(--text) 3.8%, transparent); font-size: min(58vw, 780px); font-weight: 900; line-height: .8; pointer-events: none; }
.hero .container { position: relative; z-index: 1; }
.hero h1 { max-width: 950px; margin-bottom: 25px; font-size: clamp(50px, 7.2vw, 104px); }
.hero .lead { max-width: 720px; color: var(--muted); font-size: clamp(18px, 2vw, 24px); }
.hero.compact { min-height: 410px; }
.hero.compact h1 { max-width: 850px; font-size: clamp(44px, 6vw, 76px); }
.align-center { text-align: center; }
.align-center .lead, .align-center .buttons { margin-inline: auto; justify-content: center; }
.eyebrow { margin-bottom: 18px; color: var(--accent); font-size: 12px; font-weight: 850; letter-spacing: .18em; }
.buttons { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; border: 0; border-radius: 10px; padding: 11px 18px; cursor: pointer; font-size: 13px; font-weight: 750; transition: transform .15s, box-shadow .15s, background .15s; }
.button:hover { transform: translateY(-1px); }
.button.primary { background: var(--accent); color: #fff; box-shadow: 0 9px 24px color-mix(in srgb, var(--accent) 24%, transparent); }
.button.secondary { background: color-mix(in srgb, var(--text) 6%, var(--surface)); color: var(--text); border: 1px solid color-mix(in srgb, var(--text) 12%, transparent); }

.section { padding: 105px 0; }
.section.tight { padding-block: 45px; }
.section-heading { max-width: 740px; margin-bottom: 45px; }
.section-heading h2, .text h2, .contact-intro h2 { margin-bottom: 20px; font-size: clamp(35px, 5vw, 60px); }
.section-heading > p:last-child, .text > div, .contact-intro > p { color: var(--muted); font-size: 17px; }
.text { display: grid; gap: 55px; }
.text.columns-2 { grid-template-columns: minmax(240px, .7fr) 1.3fr; }
.text > div p { max-width: 800px; }
.image-block { width: min(1180px, calc(100% - 48px)); margin: 30px auto; }
.image-block.size-narrow { width: min(760px, calc(100% - 48px)); }
.image-block.size-full { width: 100%; }
.image-block img, .image-placeholder { width: 100%; min-height: 300px; max-height: 720px; object-fit: cover; border-radius: var(--radius); }
.image-placeholder { display: grid; place-items: center; background: #e9ebee; color: var(--muted); }
.image-block figcaption { margin-top: 10px; color: var(--muted); font-size: 12px; text-align: center; }
.table-wrap { overflow-x: auto; border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); border-radius: 14px; background: var(--surface); }
table { width: 100%; border-collapse: collapse; }
th, td { border-bottom: 1px solid color-mix(in srgb, var(--text) 9%, transparent); padding: 17px 18px; text-align: left; }
th { background: color-mix(in srgb, var(--text) 4%, var(--surface)); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.callout { width: min(1000px, calc(100% - 48px)); margin: auto; border: 1px solid color-mix(in srgb, var(--accent) 18%, transparent); border-left: 5px solid var(--accent); border-radius: var(--radius); background: var(--surface); padding: 30px; box-shadow: var(--shadow); }
.callout h2 { margin-bottom: 8px; }
.callout p { margin: 0; color: var(--muted); }
.callout.tone-success { border-left-color: #25a46f; }
.callout.tone-warning { border-left-color: #e0a319; }
.button-section { width: min(1180px, calc(100% - 48px)); margin: 24px auto; }
.button-section.align-center { text-align: center; }
.button-section.align-right { text-align: right; }
.divider { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.divider span { display: block; height: 1px; background: color-mix(in srgb, var(--text) 13%, transparent); }
.spacing-small { padding-block: 20px; }
.spacing-medium { padding-block: 50px; }
.spacing-large { padding-block: 90px; }
.feature-grid, .guide-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); border-radius: var(--radius); overflow: hidden; }
.feature-grid.columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.feature-grid.columns-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.feature-grid article, .guide-grid article { min-height: 290px; padding: 30px; background: var(--surface); border-right: 1px solid color-mix(in srgb, var(--text) 10%, transparent); }
.feature-grid article:last-child, .guide-grid article:last-child { border-right: 0; }
.feature-grid article > span, .guide-grid article > span { color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: .12em; }
.feature-grid h3, .guide-grid h3 { margin-top: 70px; font-size: 25px; }
.feature-grid p, .guide-grid p { color: var(--muted); }
.feature-grid a, .guide-grid a, .guide-list a { color: var(--accent); font-size: 13px; font-weight: 750; }
.guide-grid small, .guide-list small { display: block; margin-top: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.referral { display: flex; align-items: end; justify-content: space-between; gap: 40px; border-radius: 25px; background: var(--dark); color: #fff; padding: clamp(34px, 6vw, 70px); }
.referral > div:first-child { max-width: 700px; }
.referral h2 { font-size: clamp(38px, 5vw, 62px); }
.referral p:not(.eyebrow) { color: #aeb5bf; }
.referral .secondary { color: #fff; background: #262a31; border-color: #3b414b; }
.contact-layout { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(45px, 8vw, 110px); }
.contact-intro small { color: var(--muted); }
.contact-intro aside { display: grid; margin-top: 35px; border-radius: 14px; background: color-mix(in srgb, var(--text) 5%, var(--surface)); padding: 18px; }
.contact-intro aside span { color: var(--muted); font-size: 13px; }
.contact-form { display: grid; gap: 18px; border-radius: var(--radius); background: var(--surface); padding: clamp(24px, 4vw, 42px); box-shadow: var(--shadow); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.consent, .check { display: flex; align-items: flex-start; gap: 9px; }
.consent input, .check input { width: auto; margin-top: 3px; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }

.guide-list { display: grid; gap: 1px; border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); background: color-mix(in srgb, var(--text) 10%, transparent); border-radius: var(--radius); overflow: hidden; }
.guide-list article { background: var(--surface); padding: 35px; }
.guide-list h2 { margin: 8px 0 10px; font-size: clamp(27px, 3vw, 40px); }
.guide-list p { color: var(--muted); }
.article-hero { padding: 100px 0 75px; background: var(--surface); }
.article-hero h1 { max-width: 960px; font-size: clamp(46px, 7vw, 85px); }
.article-hero > .container > p:last-child { max-width: 740px; color: var(--muted); font-size: 20px; }
.article-content { max-width: 800px; padding-block: 75px 120px; }
.article-content h2 { margin-top: 55px; font-size: 36px; }
.article-content h3 { margin-top: 35px; font-size: 26px; }
.article-content p, .article-content li { color: #454d57; font-size: 17px; line-height: 1.8; }
.article-content a { color: var(--accent); text-decoration: underline; }
.article-author { margin-top: 65px; border-top: 1px solid var(--line); padding-top: 25px; }
.site-footer { background: #111318; color: #fff; padding: 70px max(24px, calc((100vw - 1180px) / 2)) 24px; }
.site-footer > div { display: grid; grid-template-columns: minmax(250px, 2fr) repeat(3, minmax(120px, 1fr)); gap: 45px; }
.site-footer section { display: grid; align-content: start; gap: 11px; }
.site-footer section > p, .site-footer section > a, .site-footer > p { color: #aab0ba; font-size: 13px; }
.site-footer > p { margin: 55px 0 0; border-top: 1px solid #292d34; padding-top: 20px; }
.footer-brand { margin-bottom: 8px; }

.discussion-page { margin: -1px 0; background: #f0f2f4; padding: 55px 24px 90px; }
.discussion-shell { width: min(920px, 100%); margin: auto; }
.discussion-shell > header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 55px; }
.discussion-shell > header > div { color: #66707c; font-size: 13px; }
.discussion-heading { margin-bottom: 26px; }
.discussion-heading > p { color: var(--accent); font-size: 11px; font-weight: 850; letter-spacing: .16em; }
.discussion-heading h1 { margin-bottom: 10px; font-size: clamp(35px, 5vw, 58px); }
.discussion-heading span { color: var(--muted); }
.discussion-card, .thread-card { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; overflow: hidden; box-shadow: var(--shadow); }
.message-list { display: grid; gap: 18px; padding: 28px; }
.thread-message { width: min(78%, 690px); border-radius: 15px 15px 15px 4px; background: #eef0f2; padding: 16px 18px; }
.thread-message.sender-admin { justify-self: end; border-radius: 15px 15px 4px; background: #171a20; color: #fff; }
.thread-message > div { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 8px; }
.thread-message time, .thread-message small { color: #8a929c; font-size: 11px; }
.thread-message p { margin: 0; white-space: normal; }
.reply-box { display: grid; gap: 13px; border-top: 1px solid var(--line); background: #fafafa; padding: 25px; }
.reply-box .button { justify-self: end; }
.private-note { display: grid; gap: 2px; margin-top: 20px; color: var(--muted); font-size: 12px; }

.flash { position: relative; z-index: 15; width: min(1120px, calc(100% - 50px)); margin: 18px auto; border: 1px solid #b9dfce; border-radius: 10px; background: #edf9f3; color: #146b48; padding: 12px 15px; font-size: 13px; font-weight: 650; }
.flash.error { border-color: #f0c7c8; background: #fff0f0; color: #a52227; }

/* Back-office */
.admin-body { min-height: 100vh; background: #f2f3f5; color: #171a20; }
.admin-app { min-height: 100vh; }
.admin-sidebar { position: fixed; z-index: 80; inset: 0 auto 0 0; display: flex; flex-direction: column; width: 245px; background: #111318; color: #fff; }
.admin-brand { display: flex; align-items: center; gap: 11px; height: 66px; padding: 0 20px; border-bottom: 1px solid #2a2d33; }
.admin-brand div { display: grid; }
.admin-brand small { color: #8f96a0; font-size: 10px; text-transform: uppercase; letter-spacing: .12em; }
.admin-sidebar nav { display: grid; gap: 4px; padding: 17px 11px; overflow-y: auto; }
.admin-sidebar nav a { border-radius: 8px; color: #aeb4be; padding: 10px 12px; font-size: 13px; font-weight: 600; }
.admin-sidebar nav a:hover, .admin-sidebar nav a.active { background: #282c33; color: #fff; }
.admin-sidebar nav a.active { box-shadow: inset 3px 0 var(--accent); }
.admin-sidebar footer { display: grid; gap: 8px; margin-top: auto; border-top: 1px solid #2a2d33; padding: 16px 20px 20px; }
.admin-sidebar footer a { color: #c7ccd3; font-size: 12px; }
.admin-sidebar footer small { overflow: hidden; color: #707783; font-size: 10px; text-overflow: ellipsis; }
.admin-main { min-height: 100vh; margin-left: 245px; padding: 98px clamp(24px, 4vw, 60px) 70px; }
.admin-topbar { position: fixed; z-index: 60; top: 0; right: 0; left: 245px; display: flex; align-items: center; justify-content: space-between; height: 66px; border-bottom: 1px solid #dfe2e6; background: rgba(255,255,255,.92); padding: 0 clamp(24px, 4vw, 60px); backdrop-filter: blur(12px); }
.admin-topbar span { color: #68717c; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; }
.admin-topbar a { font-size: 12px; font-weight: 750; }
.admin-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; width: min(1200px, 100%); margin: 0 auto 30px; }
.admin-heading p { margin-bottom: 7px; color: var(--accent); font-size: 10px; font-weight: 850; letter-spacing: .17em; }
.admin-heading h1 { margin-bottom: 7px; font-size: clamp(32px, 4vw, 50px); }
.admin-heading span { color: #6b7480; font-size: 14px; }
.admin-panel, .stat-grid article, .admin-cards section, .upload-card, .inbox-list, .admin-table, .empty-state { border: 1px solid #e0e3e7; border-radius: 14px; background: #fff; box-shadow: 0 8px 28px rgba(25,30,38,.045); }
.admin-panel { width: min(1200px, 100%); margin-inline: auto; padding: 26px; }
.admin-panel h2 { margin: 5px 0 18px; font-size: 21px; }
.form-stack { display: grid; align-content: start; gap: 17px; }
.form-stack h2:not(:first-child) { margin-top: 22px; border-top: 1px solid #eceef0; padding-top: 24px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; }
.panel-heading h2 { margin: 0; }
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; width: min(1200px, 100%); margin: 0 auto 18px; }
.stat-grid article { display: grid; min-height: 165px; padding: 22px; }
.stat-grid article span { color: #6d7580; font-size: 12px; }
.stat-grid article b { font-size: 44px; letter-spacing: -.06em; }
.stat-grid article a { align-self: end; color: #535c67; font-size: 12px; font-weight: 750; }
.stat-grid article.accent { border-color: var(--accent); background: var(--accent); color: #fff; }
.stat-grid article.accent span, .stat-grid article.accent a { color: #fff; }
.admin-cards { display: grid; grid-template-columns: 1.25fr .75fr; gap: 18px; width: min(1200px, 100%); margin: auto; }
.admin-cards section { padding: 26px; }
.admin-cards h2 { font-size: 21px; }
.quick-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.quick-actions a { border: 1px solid #e2e5e8; border-radius: 9px; padding: 13px; font-size: 13px; font-weight: 650; }
.good { color: #18865d; }
.warning { color: #bd7b0c; }
.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; width: min(1200px, 100%); margin: auto; }
.admin-card-link { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 17px; border: 1px solid #e0e3e7; border-radius: 13px; background: #fff; padding: 20px; }
.admin-card-link > span, .mail-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: #f0f1f3; color: var(--accent); font-weight: 850; }
.admin-card-link div { display: grid; }
.admin-card-link small { color: #7a828d; }
.admin-card-link i, .admin-table i { font-size: 12px; font-style: normal; font-weight: 750; }
.admin-table, .inbox-list { width: min(1200px, 100%); margin: auto; overflow: hidden; }
.admin-table > a { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 25px; min-height: 78px; border-bottom: 1px solid #edf0f2; padding: 14px 20px; }
.admin-table > a:last-child { border-bottom: 0; }
.admin-table > a:hover, .inbox-row:hover { background: #fafbfb; }
.admin-table div { display: grid; }
.admin-table small { color: #7c8490; }
.status { border-radius: 50px; background: #eceff2; color: #6b7480; padding: 5px 9px; font-size: 10px; font-weight: 800; text-transform: uppercase; }
.status.live { background: #e4f7ee; color: #167653; }
.inbox-row { display: grid; grid-template-columns: auto minmax(150px, .45fr) 1fr auto; align-items: center; gap: 18px; min-height: 84px; border-bottom: 1px solid #eceef1; padding: 14px 19px; }
.inbox-row:last-child { border-bottom: 0; }
.inbox-row.unread { box-shadow: inset 3px 0 var(--accent); background: #fffafa; }
.inbox-row div { min-width: 0; }
.inbox-row div > * { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.inbox-row small, .inbox-row p, .inbox-row time { margin: 0; color: #7a828d; font-size: 11px; }
.empty-state { padding: 50px; text-align: center; }
.nav-editor { display: grid; gap: 9px; margin-bottom: 18px; }
.nav-row { display: grid; grid-template-columns: 1fr 1.2fr 90px auto auto 38px; align-items: center; gap: 10px; }
.nav-row label { display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.nav-row label input { width: auto; }
.nav-row > button { height: 39px; border: 0; border-radius: 8px; background: #ffeded; color: #b8262b; cursor: pointer; }
.settings-layout { display: grid; grid-template-columns: 1fr minmax(320px, .75fr); align-items: start; gap: 18px; width: min(1200px, 100%); margin: auto; }
.settings-layout .admin-panel { width: 100%; }
.color-field { display: grid; grid-template-columns: 50px 1fr; gap: 8px; }
.color-field input[type=color] { height: 43px; padding: 3px; }
.footer-columns-editor { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.footer-column { display: grid; align-content: start; gap: 12px; border: 1px solid #e2e5e8; border-radius: 12px; background: #f8f9fa; padding: 15px; }
.footer-column > header { display: grid; grid-template-columns: 1fr 38px; align-items: end; gap: 8px; }
.footer-column button[data-remove-footer-column], .footer-link-row button { height: 39px; border: 0; border-radius: 8px; background: #ffeded; color: #b8262b; cursor: pointer; }
.footer-links { display: grid; gap: 8px; }
.footer-link-row { display: grid; grid-template-columns: 1fr 1fr 38px; gap: 8px; }
.footer-add-link { justify-self: start; border: 0; background: transparent; color: #4e5863; cursor: pointer; padding: 4px 0; font-size: 12px; font-weight: 750; }
.integration-status { display: grid; gap: 3px; border: 1px solid #e8cf9c; border-radius: 10px; background: #fff9ee; padding: 14px; }
.integration-status.ready { border-color: #a9ddc8; background: #f1fbf6; }
.integration-status span, .field-help { color: #6c7580; font-size: 11px; font-weight: 400; }
.upload-card { display: grid; grid-template-columns: 1fr 2fr auto; align-items: end; gap: 15px; width: min(1200px, 100%); margin: 0 auto 20px; padding: 20px; }
.media-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; width: min(1200px, 100%); margin: auto; }
.media-grid article { overflow: hidden; border: 1px solid #e0e3e7; border-radius: 13px; background: #fff; }
.media-grid img { width: 100%; aspect-ratio: 16/10; object-fit: cover; background: #eceff2; }
.media-grid article > div { display: grid; gap: 8px; padding: 15px; }
.media-grid small { color: #7b838d; }

.editor-toolbar { position: sticky; z-index: 25; top: 66px; display: flex; align-items: center; justify-content: space-between; min-height: 64px; margin: -32px calc(clamp(24px, 4vw, 60px) * -1) 22px; border-bottom: 1px solid #dfe2e6; background: rgba(255,255,255,.96); padding: 9px clamp(24px, 4vw, 60px); backdrop-filter: blur(12px); }
.editor-toolbar > a { color: #5e6671; font-size: 12px; font-weight: 700; }
.editor-toolbar > div { display: flex; align-items: center; gap: 14px; }
.editor-toolbar > div > span { border-radius: 50px; background: #edf0f2; padding: 5px 9px; color: #6d7580; font-size: 10px; font-weight: 800; text-transform: uppercase; }
.article-editor-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; align-items: start; gap: 18px; width: min(1200px, 100%); margin: auto; }
.article-editor-layout > main { display: grid; gap: 18px; }
.article-editor-layout .admin-panel { width: 100%; }
.article-editor-layout > aside { position: sticky; top: 148px; display: grid; gap: 18px; }
.article-textarea { min-height: 560px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 14px; line-height: 1.7; }
.delete-form { width: min(1200px, 100%); margin: 30px auto 0; text-align: right; }
.delete-form button { border: 0; background: transparent; color: #ba2b30; cursor: pointer; font-size: 12px; text-decoration: underline; }

/* L’éditeur garde palette, aperçu et personnalisation visibles. Chaque zone défile seule. */
.admin-main:has(.page-editor) { height: 100vh; overflow: hidden; padding: 66px 0 0; }
.admin-main:has(.page-editor) .flash { position: fixed; top: 67px; left: calc(245px + 50%); transform: translateX(-50%); z-index: 100; }
.page-editor { height: calc(100vh - 66px); display: flex; flex-direction: column; overflow: hidden; }
.page-editor > .editor-toolbar { position: relative; top: 0; flex: 0 0 62px; margin: 0; padding-inline: 23px; }
#page-editor-form { min-height: 0; flex: 1; display: flex; flex-direction: column; }
.editor-settings { flex: 0 0 auto; display: grid; grid-template-columns: 1.1fr .8fr 1.2fr 1fr 1.2fr .75fr auto; gap: 9px; border-bottom: 1px solid #dfe2e6; background: #fff; padding: 12px 17px; }
.editor-settings label { min-width: 0; font-size: 10px; text-transform: uppercase; letter-spacing: .055em; }
.editor-settings input, .editor-settings textarea { min-height: 38px; max-height: 58px; padding: 8px 9px; font-size: 12px; text-transform: none; letter-spacing: normal; }
.editor-settings .check { align-items: center; align-self: end; min-height: 38px; }
.editor-workspace { min-height: 0; flex: 1; display: grid; grid-template-columns: 218px minmax(430px, 1fr) 340px; overflow: hidden; }
.block-library, .block-inspector, .editor-canvas { min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.block-library, .block-inspector { background: #fff; padding: 18px 14px 50px; }
.block-library { border-right: 1px solid #dfe2e6; }
.block-inspector { border-left: 1px solid #dfe2e6; }
.block-library h2, .block-inspector h2 { position: sticky; top: -18px; z-index: 2; margin: 0 -5px 13px; background: #fff; padding: 16px 5px 10px; font-size: 13px; letter-spacing: -.01em; }
[data-block-palette] { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.palette-button { display: grid; place-items: center; min-height: 66px; border: 1px solid #e0e3e7; border-radius: 9px; background: #fafbfb; color: #4f5863; cursor: pointer; padding: 8px; font-size: 10px; font-weight: 750; text-align: center; }
.palette-button span { display: block; color: var(--accent); font-size: 17px; }
.palette-button:hover { border-color: #a9afb7; background: #fff; }
.editor-canvas { background: #e9ebee; padding: 26px; }
[data-block-canvas] { display: grid; gap: 10px; width: min(780px, 100%); margin: auto; }
.canvas-block { position: relative; overflow: hidden; border: 2px solid transparent; border-radius: 11px; background: #fff; box-shadow: 0 4px 20px rgba(30,35,42,.06); cursor: pointer; }
.canvas-block:hover, .canvas-block.selected { border-color: var(--accent); }
.canvas-block-label { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #e7e9ec; background: #f8f9fa; padding: 7px 10px; color: #6c7480; font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.canvas-block-label div { display: flex; gap: 4px; }
.canvas-block-label button { display: grid; place-items: center; width: 24px; height: 24px; border: 0; border-radius: 6px; background: #fff; color: #59616c; cursor: pointer; }
.canvas-preview { padding: 20px; }
.canvas-preview.hero-preview { min-height: 230px; display: grid; align-content: center; background: radial-gradient(circle at 85% 20%, #ffe2e3, transparent 30%), #fff; }
.canvas-preview .eyebrow { margin-bottom: 8px; font-size: 8px; }
.canvas-preview h2 { max-width: 580px; margin-bottom: 8px; font-size: clamp(25px, 4vw, 45px); }
.canvas-preview h3 { font-size: 23px; }
.canvas-preview p { margin: 0; color: #69727d; font-size: 12px; }
.canvas-preview img { width: 100%; max-height: 270px; object-fit: cover; border-radius: 7px; }
.canvas-preview table { font-size: 10px; }
.canvas-preview th, .canvas-preview td { padding: 8px; }
.canvas-preview .preview-button { display: inline-flex; margin-top: 13px; border-radius: 7px; background: var(--accent); color: #fff; padding: 7px 10px; font-size: 9px; font-weight: 750; }
.canvas-empty { border: 2px dashed #cdd1d6; border-radius: 12px; padding: 60px 20px; color: #747c86; text-align: center; }
.inspector-fields { display: grid; gap: 13px; }
.inspector-fields label { font-size: 11px; }
.inspector-fields textarea { min-height: 78px; }
.inspector-note { border-radius: 8px; background: #f1f3f5; color: #6b7480; padding: 10px; font-size: 10px; }
.inspector-note a { color: var(--accent); font-weight: 750; }
.inspector-media-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-top: 8px; }
.inspector-media-grid button { overflow: hidden; border: 1px solid #dfe2e6; border-radius: 8px; background: #fff; cursor: pointer; padding: 0; text-align: left; }
.inspector-media-grid img { width: 100%; aspect-ratio: 1.35; object-fit: cover; }
.inspector-media-grid span { display: block; overflow: hidden; padding: 6px; font-size: 9px; white-space: nowrap; text-overflow: ellipsis; }
.visual-array-editor { display: grid; gap: 9px; border-top: 1px solid #e3e6e9; padding-top: 13px; }
.visual-array-heading { display: flex; align-items: center; justify-content: space-between; }
.visual-array-heading > button, .visual-add-button { border: 0; background: transparent; color: var(--accent); cursor: pointer; padding: 3px; font-size: 10px; font-weight: 800; }
.inspector-table-scroll { display: grid; gap: 5px; overflow-x: auto; }
.inspector-table-row { display: flex; gap: 4px; min-width: max-content; }
.inspector-table-row input { width: 115px; padding: 7px; font-size: 10px; }
.inspector-table-row.header > div { position: relative; }
.inspector-table-row.header > div button { position: absolute; top: -5px; right: -3px; display: grid; place-items: center; width: 17px; height: 17px; border: 0; border-radius: 50%; background: #b52b30; color: #fff; cursor: pointer; font-size: 9px; }
.inspector-table-row > button[data-remove-table-row] { width: 28px; border: 0; border-radius: 7px; background: #ffeded; color: #b52b30; cursor: pointer; }
.feature-item-editor { display: grid; gap: 8px; border: 1px solid #e1e4e7; border-radius: 9px; background: #fafbfb; padding: 10px; }
.feature-item-editor header { display: flex; justify-content: space-between; align-items: center; font-size: 11px; }
.feature-item-editor header button { width: 25px; height: 25px; border: 0; border-radius: 6px; background: #ffeded; color: #b52b30; cursor: pointer; }
.feature-item-editor input, .feature-item-editor textarea { padding: 8px; font-size: 11px; }

.conversation-layout { display: grid; grid-template-columns: minmax(0, 1fr) 275px; align-items: start; gap: 18px; width: min(1200px, 100%); margin: auto; }
.thread-card > header { border-bottom: 1px solid #e7e9ec; padding: 25px; }
.thread-card > header p { margin-bottom: 5px; color: var(--accent); font-size: 10px; font-weight: 850; letter-spacing: .12em; }
.thread-card > header h1 { margin-bottom: 5px; font-size: 31px; }
.thread-card > header span { color: #747c87; font-size: 12px; }
.conversation-info { position: sticky; top: 150px; display: grid; gap: 12px; }
.conversation-info section { display: grid; gap: 6px; border: 1px solid #e0e3e7; border-radius: 12px; background: #fff; padding: 18px; }
.conversation-info p { margin: 0; color: #7a828c; font-size: 9px; font-weight: 800; letter-spacing: .13em; }
.conversation-info a, .conversation-info span, .conversation-info section > p:last-child { color: #69717c; font-size: 11px; }
.conversation-info .mail-warning { border-color: #edcf98; background: #fffaf0; }
.conversation-info .mail-ready { border-color: #a9ddc8; background: #f2fbf7; }

.login-page { min-height: 100vh; display: grid; grid-template-columns: 1.05fr .95fr; background: #f4f5f6; }
.login-page > section { display: grid; place-items: center; padding: clamp(30px, 6vw, 90px); }
.login-brand { align-content: space-between !important; justify-items: start !important; background: #111318; color: #fff; }
.login-brand > a { display: inline-flex; align-items: center; gap: 11px; font-weight: 800; }
.login-brand h1 { max-width: 650px; font-size: clamp(50px, 7vw, 90px); }
.login-brand p { color: #9ca3ad; font-size: 18px; }
.login-card { display: grid; gap: 18px; width: min(430px, 100%); border: 1px solid #e0e3e7; border-radius: 17px; background: #fff; padding: clamp(26px, 5vw, 45px); box-shadow: var(--shadow); }
.login-card h2 { margin-bottom: -10px; font-size: 34px; }
.login-card > p { color: #707985; }
.login-card .flash { width: 100%; margin: 0; }

@media (max-width: 1100px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid.columns-4 { grid-template-columns: repeat(2, 1fr); }
  .editor-settings { grid-template-columns: repeat(3, minmax(0, 1fr)); max-height: 170px; overflow-y: auto; }
  .editor-workspace { grid-template-columns: 180px minmax(400px, 1fr) 300px; }
  .settings-layout { grid-template-columns: 1fr; }
  .settings-layout aside { position: static; }
}

@media (max-width: 820px) {
  .container { width: min(100% - 30px, 1180px); }
  .site-header { min-height: 66px; padding-inline: 15px; }
  .mobile-menu { display: block; }
  .site-header nav { position: absolute; top: 66px; right: 10px; left: 10px; display: none; align-items: stretch; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); padding: 10px; }
  .site-header.menu-open nav { display: grid; }
  .hero { min-height: 540px; }
  .hero h1 { font-size: clamp(45px, 14vw, 75px); }
  .section { padding-block: 70px; }
  .text.columns-2, .contact-layout { grid-template-columns: 1fr; gap: 35px; }
  .feature-grid, .guide-grid, .feature-grid.columns-2, .feature-grid.columns-4 { grid-template-columns: 1fr; }
  .feature-grid article, .guide-grid article { min-height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .feature-grid h3, .guide-grid h3 { margin-top: 35px; }
  .referral { display: grid; align-items: start; }
  .site-footer > div { grid-template-columns: 1fr 1fr; }
  .login-page { grid-template-columns: 1fr; }
  .login-brand { min-height: 42vh; }

  .admin-sidebar { transform: translateX(-100%); transition: transform .2s; }
  .admin-body.admin-nav-open .admin-sidebar { transform: translateX(0); box-shadow: 20px 0 50px rgba(0,0,0,.25); }
  .admin-main { margin-left: 0; padding: 90px 15px 50px; }
  .admin-topbar { left: 0; padding-inline: 15px; }
  .admin-menu { display: block; }
  .admin-topbar span { display: none; }
  .admin-heading { align-items: start; flex-direction: column; }
  .admin-cards, .card-grid, .article-editor-layout, .conversation-layout { grid-template-columns: 1fr; }
  .article-editor-layout > aside, .conversation-info { position: static; }
  .nav-row { grid-template-columns: 1fr 1fr 65px 38px; }
  .nav-row label { font-size: 0; }
  .nav-row label input { width: 22px; height: 22px; }
  .upload-card { grid-template-columns: 1fr; }
  .footer-columns-editor { grid-template-columns: 1fr; }
  .media-grid { grid-template-columns: repeat(2, 1fr); }
  .inbox-row { grid-template-columns: auto 1fr auto; }
  .inbox-row > div:nth-of-type(2) { grid-column: 2 / -1; }

  .admin-main:has(.page-editor) { padding: 66px 0 0; }
  .page-editor > .editor-toolbar { padding-inline: 12px; }
  .page-editor > .editor-toolbar b { display: none; }
  .editor-settings { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 162px; }
  .editor-workspace { grid-template-columns: 115px minmax(300px, 1fr) 280px; overflow-x: auto; }
  .block-library, .block-inspector, .editor-canvas { height: 100%; }
  [data-block-palette] { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .form-grid, .stat-grid, .quick-actions, .site-footer > div, .media-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 44px; }
  .section-heading h2, .text h2, .contact-intro h2 { font-size: 36px; }
  .thread-message { width: 92%; }
  .discussion-page { padding-inline: 12px; }
  .discussion-shell > header > div { display: none; }
  .admin-table > a { grid-template-columns: 1fr auto; }
  .admin-table i { display: none; }
  .inbox-row { grid-template-columns: auto 1fr; }
  .inbox-row time { display: none; }
}
