/* ==========================================================
   ABACHA KINGDOM
   Presidential-Class African Institutional Design
   ========================================================== */

:root {
    --forest: #123d2b;
    --forest-dark: #092b1e;
    --forest-light: #1d563c;
    --gold: #c5a45d;
    --gold-light: #e3d1a2;
    --ivory: #f8f6ef;
    --white: #ffffff;
    --ink: #24352c;
    --muted: #6d796f;
    --line: #e6e4da;
    --red: #a83c35;
    --shadow: 0 14px 40px rgba(18, 61, 43, .09);
    --radius: 14px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--ivory);
    color: var(--ink);
    font-family: "DM Sans", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.7;
}

a {
    color: var(--forest-light);
    text-decoration: none;
    transition: color .2s ease, background .2s ease;
}

a:hover {
    color: var(--gold);
}

button,
input,
select,
textarea {
    font: inherit;
}

/* Institutional top bar */

.institutional-topbar {
    background: var(--forest-dark);
    color: rgba(255,255,255,.83);
    font-size: 11px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.topbar-inner {
    width: min(1200px, calc(100% - 40px));
    min-height: 35px;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

/* Main header and navigation */

.site-header {
    position: relative;
    z-index: 10;
    background: var(--white);
    border-bottom: 1px solid var(--line);
}

.header-inner {
    width: min(1200px, calc(100% - 40px));
    min-height: 91px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 13px;
    color: var(--forest);
    flex-shrink: 0;
}

.brand:hover {
    color: var(--forest);
}

.brand-mark,
.footer-mark {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border: 2px solid var(--gold);
    border-radius: 50%;
    background: var(--forest);
    color: var(--gold-light);
    font-family: "Playfair Display", Georgia, serif;
    font-size: 22px;
    font-weight: 700;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.4;
}

.brand-copy strong {
    font-family: "Playfair Display", Georgia, serif;
    font-size: 19px;
    letter-spacing: 1.1px;
}

.brand-copy small {
    color: var(--muted);
    font-size: 10px;
    letter-spacing: .4px;
}

.main-navigation {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px 22px;
}

.main-navigation a {
    color: var(--ink);
    font-size: 12px;
    font-weight: 700;
}

.main-navigation a:hover {
    color: var(--gold);
}

.main-navigation .nav-action {
    padding: 11px 17px;
    border-radius: 4px;
    background: var(--forest);
    color: var(--white);
}

.main-navigation .nav-action:hover {
    background: var(--gold);
    color: var(--forest-dark);
}

/* Main content */

.site-main {
    min-height: 55vh;
}

.message-container {
    width: min(1100px, calc(100% - 40px));
    margin: 24px auto 0;
}

.message {
    padding: 13px 17px;
    margin-bottom: 10px;
    border-left: 4px solid var(--gold);
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 3px 14px rgba(0,0,0,.04);
}

.message.success {
    border-left-color: #27834d;
}

.message.error {
    border-left-color: var(--red);
}

.message.warning {
    border-left-color: var(--gold);
}

/* Typography and reusable elements */

h1,
h2,
h3,
h4 {
    color: var(--forest-dark);
    font-family: "Playfair Display", Georgia, serif;
    line-height: 1.2;
}

h1 {
    font-size: clamp(32px, 4vw, 48px);
}

h2 {
    font-size: clamp(25px, 3vw, 34px);
}

h3 {
    font-size: 21px;
}

p {
    margin-top: 0;
}

.eyebrow {
    display: inline-block;
    color: var(--gold);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2.4px;
    text-transform: uppercase;
}

.button,
button {
    display: inline-flex;
    min-height: 45px;
    align-items: center;
    justify-content: center;
    padding: 11px 21px;
    border: 1px solid var(--forest);
    border-radius: 4px;
    background: var(--forest);
    color: var(--white);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .3px;
    cursor: pointer;
    transition: .2s ease;
}

.button:hover,
button:hover {
    border-color: var(--gold);
    background: var(--gold);
    color: var(--forest-dark);
}

.button-gold {
    border-color: var(--gold);
    background: var(--gold);
    color: var(--forest-dark);
}

.button-gold:hover {
    border-color: var(--gold-light);
    background: var(--gold-light);
}

.button-outline {
    border-color: rgba(255,255,255,.7);
    background: transparent;
    color: var(--white);
}

.button-outline:hover {
    border-color: var(--gold);
    background: var(--gold);
    color: var(--forest-dark);
}

/* Homepage hero */

.home-hero {
    position: relative;
    overflow: hidden;
    min-height: 510px;
    padding: 85px max(7vw, 30px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
    background:
        radial-gradient(ellipse at 82% 48%, rgba(197,164,93,.17), transparent 35%),
        linear-gradient(115deg, var(--forest-dark), var(--forest) 65%, #174b34);
    color: var(--white);
}

.home-hero::before {
    position: absolute;
    inset: 0;
    content: "";
    pointer-events: none;
    opacity: .13;
    background-image: repeating-linear-gradient(
        135deg,
        transparent 0,
        transparent 32px,
        rgba(255,255,255,.15) 33px,
        transparent 34px
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    width: min(690px, 100%);
}

.home-hero h1 {
    margin: 20px 0;
    color: var(--white);
    font-size: clamp(43px, 6vw, 72px);
    letter-spacing: -.9px;
}

.home-hero h1 span {
    color: var(--gold-light);
}

.home-hero .hero-content > p {
    max-width: 620px;
    color: rgba(255,255,255,.82);
    font-size: 16px;
    line-height: 1.9;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 13px;
    margin-top: 30px;
}

.hero-motto {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 44px;
    color: var(--gold-light);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2px;
}

.hero-motto span {
    width: 35px;
    height: 2px;
    background: var(--gold);
}

.hero-emblem {
    position: relative;
    z-index: 1;
    width: 260px;
    flex-shrink: 0;
    text-align: center;
}

.emblem-ring {
    width: 220px;
    height: 220px;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--gold);
    border-radius: 50%;
    outline: 1px solid rgba(227,209,162,.4);
    outline-offset: 9px;
    color: var(--gold-light);
}

.emblem-ring span {
    font-family: "Playfair Display", Georgia, serif;
    font-size: 76px;
    font-weight: 700;
    line-height: 1;
}

.emblem-ring small {
    margin-top: 12px;
    font-size: 9px;
    letter-spacing: 2px;
}

.hero-emblem > p {
    margin-top: 30px;
    color: rgba(255,255,255,.75);
    font-family: "Playfair Display", Georgia, serif;
    font-size: 15px;
    font-style: italic;
}

/* Homepage sections */

.welcome-section,
.news-section {
    width: min(1160px, calc(100% - 40px));
    margin: auto;
    padding: 85px 0;
}

.section-heading {
    max-width: 760px;
    margin: 0 auto 42px;
    text-align: center;
}

.section-heading h2,
.news-heading h2 {
    margin: 12px 0;
}

.section-heading p,
.news-heading p {
    color: var(--muted);
    line-height: 1.9;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.feature-card {
    padding: 30px;
    border: 1px solid var(--line);
    border-top: 3px solid var(--gold);
    border-radius: 7px;
    background: var(--white);
    box-shadow: 0 8px 25px rgba(18,61,43,.035);
}

.feature-number {
    color: var(--gold);
    font-family: "Playfair Display", Georgia, serif;
    font-size: 30px;
}

.feature-card h3 {
    margin: 12px 0;
}

.feature-card p {
    margin-bottom: 0;
    color: var(--muted);
    line-height: 1.8;
}

.heritage-section {
    padding: 75px max(7vw, 30px);
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    align-items: center;
    gap: 70px;
    background: #eeece2;
}

.heritage-copy {
    max-width: 580px;
}

.heritage-copy h2 {
    margin: 15px 0;
    font-size: clamp(32px, 4vw, 45px);
}

.heritage-copy p {
    color: var(--muted);
    line-height: 1.9;
}

.text-link {
    display: inline-block;
    margin-top: 12px;
    color: var(--forest);
    font-weight: 800;
}

.heritage-panel {
    min-height: 260px;
    padding: 35px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--gold);
    outline: 1px solid rgba(197,164,93,.4);
    outline-offset: -12px;
    background: var(--forest);
    color: var(--gold-light);
    text-align: center;
}

.heritage-symbol {
    font-size: 36px;
}

.heritage-panel strong {
    margin: 10px 0;
    font-family: "Playfair Display", Georgia, serif;
    font-size: 38px;
    letter-spacing: 4px;
}

.heritage-panel small {
    font-size: 9px;
    letter-spacing: 2px;
}

.news-heading {
    margin-bottom: 28px;
}

.news-empty {
    padding: 45px 25px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    text-align: center;
}

.news-icon {
    color: var(--gold);
    font-size: 30px;
}

.news-empty h3 {
    margin: 8px 0;
}

.news-empty p {
    max-width: 560px;
    margin: auto;
    color: var(--muted);
}

.membership-banner {
    padding: 55px max(7vw, 30px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    background: var(--forest);
    color: var(--white);
}

.membership-banner h2 {
    max-width: 680px;
    margin: 10px 0;
    color: var(--white);
}

.membership-banner p {
    margin-bottom: 0;
    color: rgba(255,255,255,.75);
}

/* Existing page headings and panels */

.page-heading {
    width: min(1160px, calc(100% - 40px));
    margin: 55px auto 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
}

.page-heading h1 {
    margin: 8px 0;
}

.page-heading p:not(.eyebrow) {
    color: var(--muted);
}

.cards {
    width: min(1160px, calc(100% - 40px));
    margin: 30px auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 18px;
}

.cards article,
.village-card,
.age-grade-card {
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    box-shadow: 0 6px 20px rgba(18,61,43,.04);
}

.cards article small,
.count-label {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .5px;
}

.cards article h2 {
    margin: 8px 0 0;
    color: var(--forest);
    font-size: 34px;
}

.block-panel {
    width: min(1160px, calc(100% - 40px));
    margin: 25px auto;
    padding: 27px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.block-heading {
    position: relative;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
}

.block-heading h2 {
    margin: 7px 0;
}

.structure-label {
    color: var(--gold);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.7px;
}

.count-label {
    display: inline-block;
    margin-top: 8px;
}

.village-grid,
.age-grade-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 17px;
    margin-top: 23px;
}

.village-card,
.age-grade-card {
    background: var(--ivory);
    box-shadow: none;
}

.village-card h3,
.age-grade-card h3 {
    margin: 0 0 5px;
}

.village-card > small,
.age-grade-card > small {
    color: var(--muted);
}

.kindred-heading {
    margin-top: 20px;
    padding-top: 13px;
    border-top: 1px solid var(--line);
    color: var(--forest);
    font-size: 12px;
    font-weight: 800;
}

.kindred-item {
    padding: 7px 0;
    border-bottom: 1px solid var(--line);
    color: var(--muted);
    font-size: 13px;
}

.empty-note {
    color: var(--muted);
    font-size: 13px;
}

/* Hero sections used by administration pages */

.hero {
    padding: 48px max(7vw, 30px);
    background: linear-gradient(110deg, var(--forest-dark), var(--forest));
    color: var(--white);
}

.hero h1,
.hero h2 {
    color: var(--white);
}

.hero p {
    color: rgba(255,255,255,.78);
}

.hero small {
    color: var(--gold-light);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2px;
}

/* Login and registration */

.login,
.registration-page {
    width: min(820px, calc(100% - 36px));
    margin: 55px auto;
    padding: 38px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.login {
    max-width: 470px;
}

.login h1,
.registration-page h1 {
    margin-top: 0;
}

.registration-page h2 {
    margin-top: 35px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line);
    font-size: 23px;
}

.registration-page p {
    margin-bottom: 18px;
}

label {
    display: inline-block;
    margin-bottom: 7px;
    color: var(--forest-dark);
    font-size: 12px;
    font-weight: 800;
}

input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
select,
textarea {
    width: 100%;
    min-height: 45px;
    padding: 11px 13px;
    border: 1px solid #d9ddd5;
    border-radius: 5px;
    outline: none;
    background: #fff;
    color: var(--ink);
    font-size: 14px;
    transition: border .2s ease, box-shadow .2s ease;
}

textarea {
    min-height: 110px;
    resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(197,164,93,.15);
}

input[type="file"] {
    display: block;
    width: 100%;
    max-width: 100%;
    padding: 10px;
    border: 1px dashed #c9cfc6;
    border-radius: 5px;
    background: var(--ivory);
    color: var(--muted);
    font-size: 12px;
}

.login form label {
    display: block;
}

.login form input {
    margin-bottom: 18px;
}

.registration-page button,
.login button {
    margin-top: 12px;
}

/* Tables and application detail */

.site-main table {
    width: min(1160px, calc(100% - 40px));
    margin: 20px auto;
    border-collapse: collapse;
    background: var(--white);
    font-size: 13px;
}

.site-main th,
.site-main td {
    padding: 13px 15px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.site-main th {
    background: var(--forest);
    color: var(--white);
    font-size: 11px;
    letter-spacing: .5px;
}

.site-main tr:hover td {
    background: #f7f6f0;
}

.site-main section:not(.home-hero):not(.welcome-section):not(.heritage-section):not(.news-section):not(.membership-banner):not(.registration-page):not(.login):not(.block-panel):not(.hero) {
    margin-top: 20px;
}

.site-main section:not(.hero):not(.registration-page):not(.login):not(.block-panel) > h2,
.site-main section:not(.hero):not(.registration-page):not(.login):not(.block-panel) > p {
    max-width: 1160px;
    margin-left: auto;
    margin-right: auto;
}

.site-main section:not(.hero):not(.registration-page):not(.login):not(.block-panel) > h2 {
    padding-left: 0;
}

/* Footer */

.site-footer {
    margin-top: 65px;
    padding: 45px 0 0;
    background: var(--forest-dark);
    color: rgba(255,255,255,.75);
}

.footer-inner {
    width: min(1160px, calc(100% - 40px));
    margin: auto;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 17px;
    padding-bottom: 32px;
}

.footer-mark {
    width: 48px;
    height: 48px;
    border-color: var(--gold);
    background: transparent;
    color: var(--gold-light);
    font-size: 18px;
}

.footer-brand strong {
    color: var(--white);
    font-family: "Playfair Display", Georgia, serif;
    font-size: 18px;
    letter-spacing: 1px;
}

.footer-brand p {
    margin: 4px 0 0;
    color: rgba(255,255,255,.65);
    font-size: 12px;
}

.footer-bottom {
    min-height: 55px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    border-top: 1px solid rgba(255,255,255,.13);
    color: rgba(255,255,255,.55);
    font-size: 11px;
}

/* Responsive layouts */

@media (max-width: 900px) {
    .header-inner {
        padding: 17px 0;
        align-items: flex-start;
        flex-direction: column;
        gap: 16px;
    }

    .main-navigation {
        width: 100%;
        justify-content: flex-start;
        gap: 12px 18px;
    }

    .home-hero {
        min-height: 450px;
    }

    .hero-emblem {
        width: 190px;
    }

    .emblem-ring {
        width: 165px;
        height: 165px;
    }

    .emblem-ring span {
        font-size: 58px;
    }

    .feature-grid {
        grid-template-columns: 1fr 1fr;
    }

    .heritage-section {
        gap: 35px;
    }
}

@media (max-width: 620px) {
    .topbar-inner {
        min-height: 32px;
        font-size: 9px;
        letter-spacing: .7px;
    }

    .header-inner,
    .topbar-inner,
    .footer-inner {
        width: calc(100% - 30px);
    }

    .brand-mark {
        width: 46px;
        height: 46px;
        font-size: 19px;
    }

    .brand-copy strong {
        font-size: 16px;
    }

    .brand-copy small {
        font-size: 9px;
    }

    .main-navigation {
        gap: 12px 15px;
    }

    .main-navigation a {
        font-size: 11px;
    }

    .main-navigation .nav-action {
        padding: 8px 11px;
    }

    .home-hero {
        padding: 62px 25px;
        min-height: auto;
    }

    .home-hero h1 {
        font-size: 43px;
    }

    .home-hero .hero-content > p {
        font-size: 14px;
    }

    .hero-emblem {
        display: none;
    }

    .welcome-section,
    .news-section {
        width: calc(100% - 34px);
        padding: 58px 0;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .feature-card {
        padding: 24px;
    }

    .heritage-section {
        padding: 55px 25px;
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .heritage-panel {
        min-height: 210px;
    }

    .membership-banner {
        padding: 45px 25px;
        align-items: flex-start;
        flex-direction: column;
    }

    .page-heading {
        width: calc(100% - 34px);
        margin-top: 35px;
        align-items: flex-start;
        flex-direction: column;
    }

    .cards,
    .block-panel {
        width: calc(100% - 34px);
    }

    .cards {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .cards article {
        padding: 17px;
    }

    .cards article h2 {
        font-size: 27px;
    }

    .block-panel {
        padding: 18px;
    }

    .login,
    .registration-page {
        width: calc(100% - 28px);
        margin: 30px auto;
        padding: 23px 18px;
    }

    .footer-bottom {
        padding: 16px 0;
        align-items: flex-start;
        flex-direction: column;
    }

    .site-main table {
        font-size: 11px;
    }

    .site-main th,
    .site-main td {
        padding: 10px;
    }
}
