:root {
    --bg: #f6f1e8;
    --panel: #ffffff;
    --text: #1f2933;
    --accent: #0f766e;
    --accent-hover: #115e59;
    --border: #d8e1dc;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: linear-gradient(180deg, #fffdf8 0%, var(--bg) 100%);
    color: var(--text);
}

header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}

.top-nav {
    max-width: 1000px;
    margin: 0 auto;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.brand {
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent);
    text-decoration: none;
    white-space: nowrap;
}

.menu {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.menu a {
    display: inline-block;
    padding: 10px 14px;
    border-radius: 999px;
    text-decoration: none;
    color: var(--text);
    border: 1px solid transparent;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.menu a:hover,
.menu a:focus-visible,
.menu a.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    outline: none;
}

main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 48px 20px 64px;
}


h1,
h2,
h3,
p {
    margin-top: 0;
}

.section-title {
    color: var(--accent);
}

.page-link {
    display: inline-block;
    margin-top: 8px;
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
}

.page-link:hover,
.page-link:focus-visible {
    color: var(--accent-hover);
}


/* --- Dropdown menus (Resources + nested sub-menus) --- */

.menu li {
    position: relative;
}

.dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 190px;
    margin: 0;
    padding: 8px;
    padding-top: 16px;
    list-style: none;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 12px 24px rgba(31, 41, 51, 0.12);
    z-index: 20;
}

.menu > li.has-dropdown:hover > .dropdown,
.menu > li.has-dropdown:focus-within > .dropdown {
    display: block;
}

.dropdown li {
    list-style: none;
}

.dropdown a {
    display: block;
    padding: 10px 14px;
    border-radius: 999px;
    white-space: nowrap;
    color: var(--text);
    text-decoration: none;
    border: 1px solid transparent;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.dropdown a:hover,
.dropdown a:focus-visible {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    outline: none;
}

/* Third-level menu flies out to the right */
.dropdown .sub-dropdown {
    top: -8px;
    left: 100%;
    padding-left: 16px;
}

.dropdown li.has-dropdown:hover > .sub-dropdown,
.dropdown li.has-dropdown:focus-within > .sub-dropdown {
    display: block;
}

/* Small arrow hints */
.menu > li.has-dropdown > a::after {
    content: "▾";
    font-size: 0.65em;
    margin-left: 6px;
    vertical-align: middle;
}

.dropdown li.has-dropdown > a::after {
    content: "▸";
    float: right;
    margin-left: 10px;
    font-size: 0.65em;
}

.has-dropdown > .dropdown::before {
    content: "";
    position: absolute;
    top: -12px;
    left: 0;
    right: 0;
    height: 12px;
}