:root {
    --ink: #1c393d;
    --muted: #747373;
    --line: #e3e8e7;
    --paper: #f7f8f7;
    --white: #fff;
    --green: #02bf5a;
    --green-dark: #1c393d;
    --orange: #02bf5a;
    --shadow: 0 18px 40px rgba(28, 57, 61, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: Arial, Helvetica, sans-serif;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.site-header, footer {
    max-width: 1240px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 28px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}
.brand-icon { display: block; width: 50px; height: 50px; }
.brand-word { color: #070b0c; font-size: 28px; font-weight: 800; letter-spacing: -.04em; }
.portal-label { padding-left: 13px; color: #667579; border-left: 1px solid #d7dedd; font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; }
.site-header nav { display: flex; gap: 30px; }
.site-header nav a {
    position: relative;
    padding: 9px 0;
    color: #4d5e58;
    text-decoration: none;
    font-size: 14px;
    font-weight: 650;
}
.site-header nav a.active::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    background: var(--orange);
}

.hero {
    position: relative;
    overflow: hidden;
    padding: 92px max(28px, calc((100% - 1184px) / 2)) 54px;
    color: white;
    background:
        radial-gradient(circle at 84% 35%, rgba(88, 146, 119, .26) 0 1px, transparent 2px) 0 0 / 18px 18px,
        var(--green-dark);
}
.hero::after {
    content: "";
    position: absolute;
    width: 420px;
    height: 420px;
    right: -180px;
    top: -240px;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 50%;
    box-shadow: 0 0 0 70px rgba(255,255,255,.025), 0 0 0 140px rgba(255,255,255,.02);
}
.eyebrow, .section-label {
    margin: 0 0 22px;
    color: #d3e3dc;
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: 11px;
    font-weight: 750;
}
.eyebrow { display: flex; align-items: center; gap: 10px; }
.eyebrow span { width: 23px; height: 2px; background: var(--orange); }
.hero-layout { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 70px; align-items: end; }
.hero h1 {
    max-width: 740px;
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(52px, 7vw, 88px);
    font-weight: 400;
    letter-spacing: -.05em;
    line-height: .95;
}
.hero h1 em { color: var(--green); font-weight: 400; }
.hero-layout > div > p {
    max-width: 620px;
    margin: 28px 0 0;
    color: #bfd0c9;
    font-size: 17px;
    line-height: 1.65;
}
.portal-stats { display: flex; margin: 0 0 4px; }
.portal-stats div { min-width: 112px; padding-left: 24px; border-left: 1px solid rgba(255,255,255,.18); }
.portal-stats dt { font-family: Arial, Helvetica, sans-serif; font-size: 38px; }
.portal-stats dd { margin: 4px 0 0; color: #aebfb8; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.search {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    max-width: 780px;
    margin-top: 52px;
    padding: 7px 7px 7px 19px;
    color: var(--ink);
    background: white;
    border-radius: 10px;
    box-shadow: 0 14px 35px rgba(0,0,0,.18);
}
.search > span { color: var(--green); font-size: 25px; transform: rotate(-18deg); }
.search input {
    min-width: 0;
    padding: 15px;
    border: 0;
    outline: 0;
    color: var(--ink);
    font: inherit;
}
.search button {
    padding: 13px 22px;
    border: 0;
    border-radius: 7px;
    color: white;
    background: var(--green);
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}
.search button:hover { background: #236349; }
.search input:focus-visible, .search button:focus-visible, a:focus-visible { outline: 3px solid #e99a67; outline-offset: 3px; }

.tools-section, .about { max-width: 1240px; margin: auto; padding: 76px 28px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.section-label { color: var(--green); margin-bottom: 9px; }
.section-heading h2, .about h2 {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(34px, 4vw, 50px);
    font-weight: 400;
    letter-spacing: -.03em;
}
.section-heading > p { color: var(--muted); font-size: 13px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 32px 0; }
.filters a {
    padding: 9px 15px;
    color: #55645f;
    border: 1px solid var(--line);
    border-radius: 999px;
    text-decoration: none;
    background: rgba(255,255,255,.45);
    font-size: 13px;
    font-weight: 650;
}
.filters a:hover, .filters a.selected { color: white; border-color: var(--green); background: var(--green); }
.tool-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.tool-card {
    display: flex;
    flex-direction: column;
    min-height: 330px;
    padding: 27px;
    background: var(--white);
    border: 1px solid #e4e8e5;
    border-radius: 14px;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.tool-card:hover { transform: translateY(-4px); border-color: #c7d5cf; box-shadow: var(--shadow); }
.card-top { display: flex; align-items: start; justify-content: space-between; gap: 15px; }
.tool-icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 15px 5px 15px 5px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 18px;
    font-weight: 700;
}
.color-green { color: #246148; background: #dcece4; }
.color-orange { color: #a65121; background: #fae6d7; }
.color-blue { color: #315d7c; background: #ddeaf2; }
.color-violet { color: #684f82; background: #e9e1f0; }
.color-red { color: #8c4545; background: #f2dfdc; }
.color-teal { color: #276a68; background: #d9ecea; }
.status {
    padding: 6px 9px;
    border-radius: 5px;
    color: #7d7168;
    background: #f4f0eb;
    font-size: 10px;
    font-weight: 750;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.status-available { color: #246148; background: #e0eee7; }
.category { margin: 26px 0 8px; color: var(--green); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.tool-card h3 { margin: 0; font-family: Arial, Helvetica, sans-serif; font-size: 25px; font-weight: 400; }
.description { margin: 13px 0 24px; color: var(--muted); font-size: 14px; line-height: 1.65; }
.card-action {
    display: flex;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid #edf0ee;
    color: var(--green);
    text-decoration: none;
    font-size: 13px;
    font-weight: 750;
}
.card-action.disabled { color: #9a9f9c; }
.empty-state { padding: 70px 20px; text-align: center; background: white; border: 1px solid var(--line); border-radius: 14px; }
.empty-state > span { display: block; font-size: 42px; color: var(--green); transform: rotate(-18deg); }
.empty-state h3 { margin-bottom: 7px; font: 400 28px Arial, Helvetica, sans-serif; }
.empty-state p { color: var(--muted); }
.empty-state a { display: inline-block; margin-top: 10px; color: var(--green); font-weight: 700; }

.about { padding-top: 30px; padding-bottom: 100px; border-top: 1px solid var(--line); }
.about > p:last-child { max-width: 680px; color: var(--muted); font-size: 16px; line-height: 1.7; }
footer { padding-top: 30px; padding-bottom: 40px; border-top: 1px solid var(--line); }
footer p { color: var(--muted); font-size: 12px; }

@media (max-width: 850px) {
    .hero { padding-top: 70px; }
    .hero-layout { grid-template-columns: 1fr; gap: 35px; }
    .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 580px) {
    .site-header nav { display: none; }
    .hero { padding-top: 58px; }
    .portal-stats { display: none; }
    .search { grid-template-columns: auto 1fr; }
    .search button { grid-column: 1 / -1; }
    .tool-grid { grid-template-columns: 1fr; }
    .section-heading { align-items: start; }
    .tool-card { min-height: 300px; }
    footer { align-items: start; flex-direction: column; gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .tool-card { transition: none; }
}
