* { box-sizing: border-box; }
:root {
    --rfaf-blue: #0b3a2c;
    --rfaf-blue-dark: #062f24;
    --rfaf-green: #103d2f;
    --rfaf-red: #d8b84e;
    --rfaf-ink: #08291f;
    --rfaf-muted: #4f5f58;
    --rfaf-bg: #f4f1e8;
    --rfaf-surface: #fffdf7;
    --rfaf-line: #ded8c8;
}
body {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    background: linear-gradient(180deg, var(--rfaf-blue-dark) 0%, var(--rfaf-bg) 18%);
    color: var(--rfaf-ink);
}
.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.top-ribbon {
    background: var(--rfaf-blue-dark);
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.88rem;
}
.ribbon-inner {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.55rem 0;
    flex-wrap: wrap;
}
.container {
    width: min(1100px, calc(100% - 2rem));
    margin: 0 auto;
}
.site-header {
    background: #062F24;
    color: #fff;
    padding: 1rem 0 1.15rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 100;
}
.header-inner {
    width: min(1280px, calc(100% - 2rem));
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 0;
}
.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}
.brand-area {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    min-width: 0;
    flex: 1 1 auto;
}
.header-search {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: auto;
    flex: 0 0 auto;
}
.header-nav {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    overflow: visible;
}
.brand {
    color: #fff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    min-width: 0;
}
.brand-logo {
    width: 170px;
    height: auto;
    display: block;
    flex: none;
}
.site-header .brand-logo {
    background: #fff;
    border-radius: 18px;
    padding: 0.3rem 0.7rem;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.14);
}
.brand-text {
    display: grid;
    line-height: 1.1;
}
.brand-text strong {
    font-size: 1.02rem;
    letter-spacing: 0.01em;
}
.brand-text small {
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.82rem;
}
.main-nav {
    flex: 1 1 auto;
}
.main-nav-panel {
    display: block;
    width: 100%;
}
.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 0.65rem;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    min-width: 0;
    width: 100%;
}
.nav-item {
    position: relative;
    flex: none;
}
.nav-item.has-submenu {
    padding-bottom: 0.55rem;
    margin-bottom: -0.55rem;
}
.nav-link {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.58rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.04);
    transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
    white-space: nowrap;
}
.nav-link:hover,
.nav-link:focus-visible,
.nav-item:hover > .nav-link,
.nav-item:focus-within > .nav-link {
    color: var(--rfaf-blue-dark);
    background: var(--rfaf-red);
    border-color: rgba(216, 184, 78, 0.7);
}
.nav-link.active,
.nav-item.active > .nav-link {
    color: #fff;
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(255, 255, 255, 0.34);
}
.nav-link.active:hover,
.nav-link.active:focus-visible,
.nav-item.active:hover > .nav-link,
.nav-item.active:focus-within > .nav-link {
    color: var(--rfaf-blue-dark);
    background: var(--rfaf-red);
    border-color: rgba(216, 184, 78, 0.7);
}
.nav-item.has-submenu > .nav-link {
    padding-right: 0.8rem;
}
.submenu-indicator {
    font-size: 0.8rem;
    line-height: 1;
}
.nav-item.nav-item-actions {
    display: flex;
    align-items: center;
}
.nav-button {
    background: transparent;
    border: 1px solid var(--rfaf-line);
    border-radius: 999px;
    color: #fff;
    font: inherit;
    padding: 0.55rem 0.95rem;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
.nav-button:hover,
.nav-button:focus-visible {
    background: var(--rfaf-red);
    color: var(--rfaf-blue-dark);
    border-color: rgba(255, 255, 255, 0.24);
}
.nav-toggle {
    display: none;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    border-radius: 999px;
    padding: 0.6rem 0.95rem;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}
.nav-toggle:hover,
.nav-toggle:focus-visible {
    background: var(--rfaf-red);
    color: var(--rfaf-blue-dark);
}
.site-search {
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
    margin-left: auto;
}
.site-search input {
    min-width: 220px;
    padding: 0.7rem 0.85rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font: inherit;
}
.site-search input::placeholder { color: rgba(255,255,255,0.7); }
.site-search button {
    border: 1px solid var(--rfaf-red);
    border-radius: 999px;
    background: var(--rfaf-red);
    color: var(--rfaf-blue-dark);
    padding: 0.7rem 1rem;
    font: inherit;
    cursor: pointer;
    font-weight: 700;
}
.site-search-inline {
    margin: 1rem 0 0;
}
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    font-size: 0.9rem;
    color: var(--rfaf-muted);
    margin-bottom: 1rem;
}
.breadcrumb a {
    color: var(--rfaf-red);
    text-decoration: none;
}
.breadcrumb-search {
    margin-bottom: 0.6rem;
}
.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 240px;
    padding: 0.55rem;
    margin: 0;
    list-style: none;
    background: linear-gradient(180deg, rgba(6, 47, 36, 0.98), rgba(11, 58, 44, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 18px;
    box-shadow: 0 18px 36px rgba(6, 47, 36, 0.22);
    z-index: 9999;
}
.nav-item:hover > .submenu,
.nav-item:focus-within > .submenu {
    display: block;
}
.submenu .nav-item {
    width: 100%;
}
.submenu .nav-item.has-submenu {
    position: relative;
    padding-right: 0.55rem;
    margin-right: -0.55rem;
}
.submenu .nav-item.has-submenu::after {
    content: '';
    position: absolute;
    top: 0;
    right: -0.55rem;
    width: 0.55rem;
    height: 100%;
}
.submenu .nav-link {
    width: 100%;
    justify-content: space-between;
    border-radius: 14px;
    border-color: transparent;
    background: transparent;
    color: #fff;
    padding: 0.62rem 0.85rem;
}
.submenu .nav-link:hover,
.submenu .nav-link:focus-visible {
    background: rgba(216, 184, 78, 0.18);
    color: #fff;
}
.submenu .submenu {
    top: 0;
    left: calc(100% + 0.2rem);
}
.submenu .submenu-indicator {
    transform: rotate(-90deg);
}
.content { padding: 2rem 0 3rem; flex: 1; }
.hero, .panel, .preview-shell {
    background: var(--rfaf-surface);
    border-radius: 22px;
    padding: 1.5rem;
    box-shadow: 0 14px 34px rgba(6, 47, 36, 0.07);
    border: 1px solid var(--rfaf-line);
    margin-bottom: 1.25rem;
}
.grid {
    display: grid;
    grid-template-columns: 1.35fr 0.9fr;
    gap: 1rem;
}
.page-hero {
    background: linear-gradient(135deg, var(--rfaf-green) 0%, var(--rfaf-blue-dark) 100%);
    border-radius: 34px;
    overflow: hidden;
    box-shadow: 0 22px 50px rgba(6, 47, 36, 0.18);
    border: 1px solid var(--rfaf-line);
    margin-bottom: 1.25rem;
}
.page-hero-center {
    display: grid;
    gap: 1.5rem;
    padding-bottom: 2rem;
}
.page-hero-page {
    padding-bottom: 1.25rem;
}
.hero-kicker-light {
    color: rgba(255, 255, 255, 0.72);
}
.hero-actions {
    margin-top: 0.5rem;
}
.hero-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    padding: 0 1.5rem 1.5rem;
}
.hero-metrics article {
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.06);
    padding: 1rem 1.1rem;
    color: #fff;
}
.hero-metrics span {
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.68);
    margin-bottom: 0.35rem;
}
.hero-metrics strong {
    font-size: 1.05rem;
    font-weight: 700;
}
.hero-banner {
    background: linear-gradient(135deg, var(--rfaf-green), var(--rfaf-blue-dark));
    min-height: 270px;
    display: grid;
    place-items: end center;
    padding: 1.5rem;
    position: relative;
}
.hero-banner-small { min-height: 180px; }
.hero-banner-title {
    color: white;
    font-size: clamp(2rem, 4vw, 4rem);
    letter-spacing: 0.05em;
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1;
    margin-bottom: 0.2rem;
}
.hero-logo-wrap {
    display: grid;
    place-items: center;
    padding: 0 1.5rem;
}
.hero-logo-wrap-small {
    margin-top: -30px;
}
.hero-logo {
    width: min(840px, 92%);
    height: auto;
    display: block;
}
.hero-copy-center {
    padding: 0 1.5rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.82);
}
.justify-center {
    justify-content: center;
}
.hero {
    background:
        radial-gradient(circle at top right, rgba(216, 184, 78, 0.18), transparent 24%),
        linear-gradient(140deg, var(--rfaf-blue-dark) 0%, var(--rfaf-green) 48%, #174935 100%);
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 1rem;
    align-items: stretch;
}
.hero-copy {
    display: grid;
    align-content: center;
    gap: 1rem;
}
.hero-copy h1 {
    font-size: clamp(2rem, 4vw, 3.3rem);
    line-height: 1.02;
    margin: 0;
    color: #fff;
}
.hero-copy p {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    max-width: 58ch;
    font-size: 1.05rem;
}
.auth-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}
.auth-brand img {
    width: 175px;
    height: auto;
}
.hero-media {
    background: linear-gradient(180deg, rgba(6, 47, 36, 0.98), rgba(11, 58, 44, 0.98));
    color: white;
    border-radius: 18px;
    padding: 1.25rem;
    display: grid;
    gap: 1rem;
    align-content: space-between;
    min-height: 280px;
    position: relative;
    overflow: hidden;
}
.hero-media::before {
    content: '';
    position: absolute;
    inset: auto -20% -25% auto;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
}
.hero-media .eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.72rem;
    color: rgba(255,255,255,0.78);
}
.hero-media .metric {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1;
}
.hero-media .metric-label {
    color: rgba(255,255,255,0.82);
}
.card, .list-item {
    border-top: 1px solid var(--rfaf-line);
    padding-top: 1rem;
    margin-top: 1rem;
}
.card.featured {
    display: grid;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid var(--rfaf-line);
    border-radius: 18px;
    background: linear-gradient(180deg, var(--rfaf-surface), #f7f4ea);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}
.card.featured h3,
.card.featured p,
.list-item h3,
.list-item p {
    margin: 0;
}
.search-results {
    display: grid;
    gap: 1rem;
}
.search-attachments {
    border-top: 1px solid var(--rfaf-line);
    padding-top: 0.75rem;
}
.search-attachments ul {
    margin: 0.5rem 0 0;
    padding-left: 1.2rem;
}
.search-attachments li + li {
    margin-top: 0.25rem;
}
.card-media {
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #e9e2d2, #f6f1e4);
}
.card-media img,
.hero-image img,
.preview-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.hero-image {
    border-radius: 18px;
    overflow: hidden;
    min-height: 280px;
    background: linear-gradient(135deg, #efe7d5, #f7f1e3);
}
.section-title {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 1rem;
    margin-bottom: 0.75rem;
}
.section-title h2,
.section-title p {
    margin: 0;
}
.section-title p {
    color: var(--rfaf-muted);
}
.prose p { line-height: 1.8; color: var(--rfaf-ink); }
a { color: var(--rfaf-blue); }

.panel-header {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}
.button, .button-secondary, .link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    padding: 0.7rem 1rem;
    border: 1px solid transparent;
    text-decoration: none;
    cursor: pointer;
    font: inherit;
}
.button {
    background: linear-gradient(135deg, var(--rfaf-red), var(--rfaf-red));
    color: var(--rfaf-blue-dark);
    box-shadow: 0 12px 20px rgba(216, 184, 78, 0.22);
}
.button-secondary {
    background: #f6f0df;
    color: var(--rfaf-blue-dark);
    border-color: var(--rfaf-line);
}
.hero-actions .button-secondary,
.hero .button-secondary,
.team-hero .button-secondary {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.24);
}
.hero-actions .button-secondary:hover,
.hero-actions .button-secondary:focus-visible,
.hero .button-secondary:hover,
.hero .button-secondary:focus-visible,
.team-hero .button-secondary:hover,
.team-hero .button-secondary:focus-visible {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}
.link-button {
    background: transparent;
    color: var(--rfaf-red);
    padding: 0;
}
.table-wrap { overflow-x: auto; }
.admin-table {
    width: 100%;
    border-collapse: collapse;
}
.admin-table th,
.admin-table td {
    text-align: left;
    padding: 0.85rem 0.75rem;
    border-bottom: 1px solid var(--rfaf-line);
    vertical-align: top;
}
.actions-cell {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}
.actions-cell form { margin: 0; }
.sr-only-form {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.tree-toolbar {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: end;
    margin-bottom: 1rem;
}
.tree-toolbar label {
    display: grid;
    gap: 0.45rem;
    min-width: min(100%, 280px);
}
.tree-toolbar input,
.tree-toolbar select {
    width: 100%;
    border: 1px solid var(--rfaf-line);
    border-radius: 10px;
    padding: 0.75rem 0.85rem;
    font: inherit;
    background: #fff;
}
.tree-toolbar-actions {
    display: flex;
    gap: 0.65rem;
    flex-wrap: wrap;
}
.tree-title-cell {
    min-width: 320px;
}
.tree-node {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    padding-left: calc(var(--tree-depth, 0) * 1.15rem);
}
.tree-toggle {
    width: 1.85rem;
    height: 1.85rem;
    border-radius: 999px;
    border: 1px solid var(--rfaf-line);
    background: #fff;
    color: var(--rfaf-blue-dark);
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    margin-top: 0.05rem;
    cursor: pointer;
    text-decoration: none;
}
.tree-toggle:hover,
.tree-toggle:focus-visible {
    text-decoration: none;
}
.tree-toggle-spacer {
    opacity: 0.35;
    cursor: default;
}
.tree-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    color: var(--rfaf-muted);
    font-size: 0.84rem;
    margin-top: 0.2rem;
}
.tree-badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.15rem 0.55rem;
    background: #f6f0df;
    color: var(--rfaf-blue-dark);
}
.tree-actions {
    min-width: 250px;
}
.doc-url-field {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}
.doc-url-field input {
    min-width: 0;
    flex: 1 1 auto;
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}
.form-grid label {
    display: grid;
    gap: 0.45rem;
}
.form-grid input,
.form-grid select,
.form-grid textarea {
    width: 100%;
    border: 1px solid var(--rfaf-line);
    border-radius: 10px;
    padding: 0.75rem 0.85rem;
    font: inherit;
    background: #fff;
}
.form-grid textarea { resize: vertical; }
.editor-toolbar {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.5rem 0 0.65rem;
    padding: 0.6rem;
    border: 1px solid var(--rfaf-line);
    border-radius: 14px;
    background: linear-gradient(180deg, #fff, #faf7ef);
}
.editor-toolbar button {
    border: 1px solid var(--rfaf-line);
    background: #fff;
    color: var(--rfaf-ink);
    border-radius: 10px;
    padding: 0.5rem 0.7rem;
    font: inherit;
    cursor: pointer;
    min-width: 2.2rem;
}
.editor-toolbar button:hover {
    border-color: var(--rfaf-red);
}
.editor-toolbar select {
    border: 1px solid var(--rfaf-line);
    background: #fff;
    color: var(--rfaf-ink);
    border-radius: 10px;
    padding: 0.5rem 0.7rem;
    font: inherit;
}
.editor-surface {
    min-height: 420px;
    border: 1px solid var(--rfaf-line);
    border-radius: 10px;
    padding: 0.9rem 1rem;
    background: #fff;
    line-height: 1.7;
    outline: none;
}
.editor-surface:focus {
    border-color: var(--rfaf-red);
    box-shadow: 0 0 0 3px rgba(216, 184, 78, 0.18);
}
.editor-surface h2 { margin: 1rem 0 0.5rem; }
.editor-surface p { margin: 0 0 0.75rem; }
.editor-surface blockquote {
    margin: 0 0 0.9rem;
    padding: 0.8rem 1rem;
    border-left: 4px solid var(--rfaf-red);
    background: #fbf6ea;
    border-radius: 0 14px 14px 0;
}
.editor-surface pre {
    margin: 0 0 0.9rem;
    padding: 0.9rem 1rem;
    background: #f7f1e4;
    border: 1px solid var(--rfaf-line);
    border-radius: 14px;
    overflow: auto;
}
.editor-surface hr {
    border: 0;
    border-top: 1px solid var(--rfaf-line);
    margin: 1rem 0;
}
.editor-surface img,
.editor-surface video {
    max-width: 100%;
    height: auto;
}
.editor-surface img.is-editor-selected,
.editor-surface video.is-editor-selected {
    outline: 3px solid rgba(216, 184, 78, 0.35);
    outline-offset: 2px;
}
.prose img,
.prose video {
    max-width: 100%;
    height: auto;
}
.team-hero {
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid var(--rfaf-line);
    background:
        radial-gradient(circle at top right, rgba(216, 184, 78, 0.16), transparent 24%),
        linear-gradient(135deg, var(--rfaf-green) 0%, var(--rfaf-blue-dark) 100%);
    box-shadow: 0 18px 44px rgba(6, 47, 36, 0.18);
    margin-bottom: 1.5rem;
}
.breadcrumb-on-hero {
    margin: 0;
    padding: 1rem 1.25rem 0;
}
.team-hero-inner {
    padding: 1.25rem 1.25rem 1.5rem;
}
.team-hero-copy {
    max-width: 760px;
}
.hero-kicker {
    margin: 0 0 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--rfaf-red);
    font-size: 0.75rem;
    font-weight: 800;
}
.team-hero-copy h1 {
    margin: 0;
    color: #fff;
    font-size: clamp(2rem, 4vw, 3.25rem);
    line-height: 1.05;
}
.team-detail-content h1 {
    margin: 0;
    color: var(--rfaf-blue-dark);
    font-size: clamp(2rem, 4vw, 3.25rem);
    line-height: 1.05;
}
.team-hero-copy p {
    margin: 0.9rem 0 0;
    max-width: 70ch;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.05rem;
    line-height: 1.8;
}
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
    margin-top: 1.25rem;
}
.team-header {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-radius: 18px;
    background:
        radial-gradient(circle at top right, rgba(216, 184, 78, 0.18), transparent 26%),
        linear-gradient(135deg, var(--rfaf-surface) 0%, #f6f0df 100%);
    border: 1px solid var(--rfaf-line);
}
.team-header h1,
.team-header p {
    margin: 0;
}
.team-header p {
    color: var(--rfaf-muted);
    margin-top: 0.35rem;
}
.team-header-meta {
    min-width: 160px;
    text-align: right;
    display: grid;
    gap: 0.15rem;
}
.team-header-meta strong {
    font-size: 2rem;
    line-height: 1;
    color: var(--rfaf-green);
}
.team-header-meta span {
    color: var(--rfaf-muted);
    font-size: 0.9rem;
}
.role-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0 0;
}
.role-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    border: 1px solid var(--rfaf-line);
    background: #fff;
    color: var(--rfaf-ink);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.93rem;
}
.role-pill.is-active {
    background: var(--rfaf-red);
    color: #fff;
    border-color: var(--rfaf-red);
}
.team-card {
    border: 1px solid var(--rfaf-line);
    border-radius: 24px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 10px 24px rgba(6, 47, 36, 0.08);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}
.team-card:hover,
.team-card:focus-within {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(6, 47, 36, 0.14);
    border-color: rgba(216, 184, 78, 0.28);
}
.team-card-photo {
    display: grid;
    place-items: center;
    aspect-ratio: 16 / 10;
    background: linear-gradient(135deg, #f2ead8, #fbf6ea);
    text-decoration: none;
    color: var(--rfaf-muted);
    font-size: 3.25rem;
    font-weight: 700;
    overflow: hidden;
}
.team-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 10%;
    display: block;
    transition: transform 240ms ease;
}
.team-card:hover .team-card-photo img,
.team-card:focus-within .team-card-photo img {
    transform: scale(1.06);
}
.team-card-body {
    padding: 0.8rem 0.9rem 0.95rem;
}
.team-card-role {
    display: inline-flex;
    align-items: center;
    margin: 0 0 0.55rem;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--rfaf-red);
    background: rgba(216, 184, 78, 0.15);
    font-size: 0.74rem;
    font-weight: 700;
}
.team-card-role-large {
    margin-bottom: 0.9rem;
}
.team-card-body h2,
.team-card-body h3 {
    margin: 0 0 0.3rem;
    font-size: 1.08rem;
}
.team-card-body p {
    margin: 0 0 0.55rem;
    color: var(--rfaf-muted);
}
.team-card-body h2 a,
.team-card-body h3 a {
    color: var(--rfaf-green);
    text-decoration: none;
}
.team-card-body h2 a:hover,
.team-card-body h3 a:hover {
    color: var(--rfaf-blue-dark);
}
.team-card-button {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--rfaf-blue-dark);
    text-decoration: none;
    font-weight: 600;
}
.team-card-button::after {
    content: '→';
    transition: transform 180ms ease;
}
.team-card-button:hover::after,
.team-card-button:focus-visible::after {
    transform: translateX(2px);
}
.team-detail-shell {
    display: grid;
    gap: 1rem;
}
.team-detail-layout {
    display: grid;
    grid-template-columns: minmax(280px, 340px) 1fr;
    gap: 1.5rem;
    align-items: start;
}
.team-detail-aside {
    display: grid;
    gap: 1rem;
}
.team-detail-photo {
    border-radius: 26px;
    overflow: hidden;
    background: linear-gradient(135deg, #f2ead8, #fbf6ea);
    box-shadow: 0 14px 32px rgba(6, 47, 36, 0.09);
}
.team-detail-photo img,
.team-admin-preview {
    width: 100%;
    height: auto;
    display: block;
}
.team-detail-photo img {
    object-position: center top;
}
.team-detail-meta {
    padding: 1rem 1.05rem;
    border-radius: 22px;
    background: #fff;
    border: 1px solid var(--rfaf-line);
    box-shadow: 0 10px 24px rgba(6, 47, 36, 0.05);
}
.team-detail-facts {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    display: grid;
    gap: 0.75rem;
}
.team-detail-facts li {
    display: grid;
    gap: 0.2rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(222, 216, 200, 0.95);
}
.team-detail-facts li:first-child {
    border-top: 0;
    padding-top: 0;
}
.team-detail-facts strong {
    color: var(--rfaf-muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.team-detail-facts span {
    color: var(--rfaf-ink);
    font-weight: 600;
}
.team-detail-button {
    width: 100%;
}
.team-detail-content {
    padding: 1.25rem 1.25rem 1.5rem;
    border-radius: 26px;
    background: #fff;
    border: 1px solid var(--rfaf-line);
    box-shadow: 0 14px 34px rgba(6, 47, 36, 0.06);
}
.team-detail-content .hero-kicker {
    color: var(--rfaf-green);
}
.team-detail-content .prose {
    margin-top: 1rem;
}
.team-detail-content .prose p:first-child {
    margin-top: 0;
}
.team-detail-content .prose p {
    line-height: 1.85;
    color: var(--rfaf-ink);
}
.team-detail-content .prose ul,
.team-detail-content .prose ol {
    padding-left: 1.3rem;
}
.team-detail-content .prose li + li {
    margin-top: 0.3rem;
}
.team-detail-copy h1 {
    margin-top: 0;
    margin-bottom: 0.35rem;
}
.team-detail-actions {
    margin: 0 0 1rem;
}
.team-photo-placeholder {
    border-radius: 0;
    aspect-ratio: 4 / 5;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #efe7d5, #f7f1e3);
    color: var(--rfaf-muted);
    font-size: 4rem;
    font-weight: 700;
}
.avatar-thumb {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
    display: block;
}
.avatar-placeholder {
    display: grid;
    place-items: center;
    background: #f6f0df;
    color: var(--rfaf-muted);
    font-size: 0.8rem;
}
.actions-cell {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}
.field-label {
    font-weight: 600;
    display: inline-block;
    margin-bottom: 0.35rem;
}
.help-text {
    margin: 0.45rem 0 0;
    color: var(--rfaf-muted);
    font-size: 0.88rem;
}
.sort-input {
    max-width: 90px;
}
.full-width { grid-column: 1 / -1; }
.checkbox-row {
    align-items: center;
    grid-template-columns: auto 1fr;
}
.form-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.notice {
    background: #f6f0df;
    color: var(--rfaf-blue-dark);
    border: 1px solid var(--rfaf-line);
    padding: 0.85rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}
.notice-error {
    background: #f6f0df;
    color: var(--rfaf-blue-dark);
    border-color: var(--rfaf-line);
}

.auth-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem 0;
}
.auth-card {
    width: min(520px, 100%);
}
.auth-form { margin-top: 1rem; }

.site-footer {
    padding: 2rem 0 3rem;
    color: rgba(255, 255, 255, 0.8);
    background: linear-gradient(180deg, var(--rfaf-blue-dark), var(--rfaf-green));
    margin-top: auto;
}
.footer-grid {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
}
.footer-grid p {
    margin: 0.25rem 0 0;
}

.image-picker {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1rem;
    align-items: start;
}
.image-preview-box {
    border-radius: 18px;
    background: #f6f0df;
    min-height: 220px;
    border: 1px dashed var(--rfaf-line);
    overflow: hidden;
}
.image-preview-box img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}
.image-placeholder {
    min-height: 220px;
    display: grid;
    place-items: center;
    color: var(--rfaf-muted);
}
.is-hidden { display: none !important; }

.preview-shell {
    padding: 0;
    overflow: hidden;
}
.preview-hero {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    min-height: 320px;
}
.preview-copy {
    padding: 2rem;
    display: grid;
    gap: 1rem;
    align-content: center;
}
.preview-copy .meta {
    color: var(--rfaf-muted);
    font-size: 0.92rem;
}
.preview-media {
    background: linear-gradient(135deg, #efe7d5, #f7f1e3);
    min-height: 100%;
}
.preview-body {
    padding: 2rem;
}
.page-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1rem;
    align-items: start;
}
.sidebar-card {
    position: sticky;
    top: 1rem;
}

.page-detail-shell {
    display: grid;
    gap: 1.25rem;
}
.page-detail-hero {
    border-radius: 32px;
    overflow: hidden;
    border: 1px solid var(--rfaf-line);
    background:
        radial-gradient(circle at top right, rgba(216, 184, 78, 0.16), transparent 22%),
        linear-gradient(135deg, var(--rfaf-green) 0%, var(--rfaf-blue-dark) 100%);
    box-shadow: 0 20px 44px rgba(6, 47, 36, 0.18);
}
.page-detail-hero-inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    align-items: center;
    padding: 1.25rem 1.25rem 1rem;
}
.page-detail-hero-copy {
    max-width: 820px;
}
.page-detail-hero-copy h1 {
    margin: 0;
    color: #fff;
    font-size: clamp(2rem, 4vw, 3.3rem);
    line-height: 1.05;
}
.page-detail-hero-copy p {
    margin: 0.9rem 0 0;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.02rem;
    line-height: 1.8;
}
.page-detail-hero-media {
    padding: 0 1.25rem 1.25rem;
}
.page-detail-hero-media img {
    display: block;
    width: 100%;
    border-radius: 24px;
    aspect-ratio: 16 / 7;
    object-fit: cover;
}
.page-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
    align-items: start;
}
.card-surface,
.page-side-card,
.result-card {
    background: var(--rfaf-surface);
    border: 1px solid var(--rfaf-line);
    border-radius: 26px;
    box-shadow: 0 14px 34px rgba(6, 47, 36, 0.06);
}
.page-detail-content {
    padding: 1.35rem;
}
.page-side-card-inline {
    margin-bottom: 1rem;
}
.page-detail-content .prose p:first-child {
    margin-top: 0;
}
.page-detail-content .prose p,
.page-detail-content .prose li {
    line-height: 1.85;
}
.page-detail-content .prose {
    overflow-x: auto;
}
.page-detail-content .prose table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    display: block;
    overflow-x: auto;
    max-width: 100%;
}
.page-detail-content .prose table th,
.page-detail-content .prose table td {
    border: 1px solid var(--rfaf-line);
    padding: 0.7rem 0.8rem;
    vertical-align: top;
}
.page-detail-content .prose table th {
    background: #f6f0df;
    color: var(--rfaf-blue-dark);
}
.page-detail-content .prose img,
.page-detail-content .prose video,
.page-detail-content .prose iframe {
    max-width: 100%;
}
.page-detail-sidebar {
    display: grid;
    gap: 1rem;
}
.page-side-card {
    padding: 1.15rem;
}
.page-side-card h2 {
    margin: 0 0 0.9rem;
    color: var(--rfaf-blue-dark);
}
.side-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.65rem;
}
.side-list a {
    color: var(--rfaf-green);
    text-decoration: none;
}
.side-list a:hover,
.side-list a:focus-visible {
    color: var(--rfaf-red);
}
.search-in-hero {
    padding: 0 1.25rem 1.25rem;
    margin: 0;
}
.search-in-hero input {
    border-color: rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.08);
}
.search-in-hero button {
    border-color: var(--rfaf-red);
}
.search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}
.result-card {
    overflow: hidden;
}
.result-card-media {
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: linear-gradient(135deg, #efe7d5, #fbf6ea);
}
.result-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.result-card-body {
    padding: 1.15rem 1.15rem 1rem;
}
.result-card-body h2 {
    margin: 0 0 0.5rem;
    font-size: 1.2rem;
}
.result-card-body p {
    margin: 0 0 0.9rem;
    color: var(--rfaf-muted);
    line-height: 1.75;
}
.result-card-attachments {
    padding: 0 1.15rem 1.15rem;
}
.result-card-attachments strong {
    display: block;
    margin-bottom: 0.45rem;
    color: var(--rfaf-blue-dark);
}

@media (max-width: 900px) {
    .grid,
    .hero,
    .preview-hero,
    .page-layout,
    .image-picker,
    .team-detail {
        grid-template-columns: 1fr;
    }
    .site-search {
        width: 100%;
        margin-left: 0;
    }
    .site-search input {
        min-width: 0;
        flex: 1;
    }
    .site-search {
        display: none;
        width: 100%;
        margin-left: 0;
    }
    .nav-toggle {
        display: inline-flex;
        justify-content: center;
        margin-left: auto;
    }
    .header-top {
        flex-wrap: wrap;
    }
    .brand-area {
        flex: 1 1 100%;
        order: 1;
    }
    .nav-toggle {
        order: 2;
    }
    .header-search {
        flex: 1 1 100%;
        width: 100%;
        order: 3;
        margin-left: 0;
    }
    .header-nav {
        width: 100%;
        order: 4;
        justify-content: flex-start;
        overflow-x: visible;
    }
    .main-nav-panel {
        display: none;
        width: 100%;
    }
    .site-header[data-nav-open="true"] .main-nav-panel {
        display: block;
    }
    .site-header[data-nav-open="true"] .site-search {
        display: flex;
        width: 100%;
        order: 4;
        margin-top: 0.8rem;
    }
    .nav-menu {
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 0.45rem;
        min-width: 0;
    }
    .nav-item,
    .nav-item.nav-item-actions {
        width: 100%;
    }
    .nav-link,
    .nav-button {
        width: 100%;
        justify-content: space-between;
    }
    .nav-item.has-submenu {
        padding-bottom: 0;
        margin-bottom: 0;
    }
    .submenu {
        position: static;
        min-width: 0;
        box-shadow: none;
        margin-top: 0.35rem;
    }
    .nav-item--open > .submenu {
        display: block;
    }
    .submenu .submenu {
        left: 0;
        top: 0;
        margin-top: 0.35rem;
    }
    .submenu .nav-item.has-submenu {
        padding-right: 0;
        margin-right: 0;
    }
    .submenu .nav-item.has-submenu::after {
        display: none;
    }
    .submenu .nav-link {
        padding-left: 1rem;
    }
    .brand-logo,
    .auth-brand img {
        width: 145px;
    }
    .team-header {
        align-items: start;
    }
    .team-header-meta {
        text-align: left;
        min-width: 0;
    }
    .team-detail-content,
    .team-detail-meta,
    .team-hero-inner {
        padding: 1rem;
    }
    .hero-metrics {
        grid-template-columns: 1fr;
        padding: 0 1rem 1rem;
    }
    .page-detail-layout,
    .page-detail-hero-inner {
        grid-template-columns: 1fr;
    }
    .page-detail-hero-brand {
        padding-left: 0;
        justify-content: start;
    }
}

@media (max-width: 700px) {
    .team-grid {
        grid-template-columns: 1fr;
    }
    .team-detail-layout {
        grid-template-columns: 1fr;
    }
    .search-results-grid {
        grid-template-columns: 1fr;
    }
    .form-grid { grid-template-columns: 1fr; }
}
