:root{
    color-scheme:dark;
    --bg:#090916;
    --bg2:#0d0d20;
    --surface:#14142b;
    --surface2:#191934;
    --border:#2a2a4d;
    --text:#f6f6ff;
    --muted:#aaaac2;
    --primary:#7b72ff;
    --primary2:#5fd5ff;
    --critical:#ff6680;
    --high:#ff8e6b;
    --medium:#f6c85f;
    --low:#70d69b;
    --info:#75b8ff;
    --radius:16px;
}

*{
    box-sizing:border-box;
}

html{
    scroll-behavior:smooth;
}

body{
    margin:0;
    background:
        radial-gradient(
            circle at 50% -10%,
            #201a55 0,
            #10102a 28%,
            var(--bg) 58%
        );
    color:var(--text);
    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    min-height:100vh;
}

a{
    color:inherit;
}

button,
textarea,
select{
    font:inherit;
}

.shell{
    width:min(1180px,calc(100% - 32px));
    margin-inline:auto;
}

.topbar{
    min-height:70px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
}

.brand{
    display:inline-flex;
    align-items:center;
    gap:10px;
    text-decoration:none;
    font-weight:850;
}

.logo{
    width:34px;
    height:34px;
    border-radius:10px;
    display:grid;
    place-items:center;
    background:
        linear-gradient(
            135deg,
            var(--primary),
            var(--primary2)
        );
    color:white;
}

.status{
    display:inline-flex;
    padding:7px 11px;
    border:1px solid var(--border);
    border-radius:999px;
    color:var(--muted);
    font-size:12px;
}

.hero{
    padding:70px 0 34px;
    text-align:center;
}

.hero h1{
    margin:0;
    font-size:clamp(38px,7vw,70px);
    line-height:1.02;
    letter-spacing:-.045em;
    background:
        linear-gradient(
            90deg,
            #a39dff,
            #5fd7ff
        );
    -webkit-background-clip:text;
    background-clip:text;
    color:transparent;
}

.hero p{
    width:min(780px,100%);
    margin:20px auto 0;
    color:var(--muted);
    line-height:1.7;
    font-size:18px;
}

.card{
    background:
        linear-gradient(
            180deg,
            rgba(25,25,52,.96),
            rgba(18,18,39,.96)
        );
    border:1px solid var(--border);
    border-radius:var(--radius);
    box-shadow:
        0 20px 70px rgba(0,0,0,.22);
}

.tool-layout{
    display:grid;
    grid-template-columns:minmax(0,1.55fr) minmax(280px,.65fr);
    gap:18px;
    align-items:start;
}

.editor-card{
    overflow:hidden;
}

.editor-head{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    padding:18px 20px;
    border-bottom:1px solid var(--border);
}

.editor-head h2{
    margin:0;
    font-size:18px;
}

.editor-actions{
    display:flex;
    gap:8px;
    flex-wrap:wrap;
}

.btn{
    border:1px solid var(--border);
    background:#202040;
    color:var(--text);
    border-radius:11px;
    padding:10px 13px;
    cursor:pointer;
    font-weight:720;
}

.btn:hover{
    border-color:#57578a;
}

.btn.primary{
    background:
        linear-gradient(
            135deg,
            var(--primary),
            #5e59dd
        );
    border-color:transparent;
}

textarea{
    width:100%;
    min-height:470px;
    display:block;
    resize:vertical;
    border:0;
    outline:0;
    padding:20px;
    background:#0d0d1c;
    color:#e8e8fa;
    line-height:1.62;
    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        monospace;
    font-size:13px;
    tab-size:2;
}

.editor-foot{
    padding:14px 20px;
    border-top:1px solid var(--border);
    color:var(--muted);
    display:flex;
    justify-content:space-between;
    gap:12px;
    flex-wrap:wrap;
    font-size:12px;
}

.summary-card{
    padding:20px;
}

.summary-card h2{
    margin:0 0 16px;
}

.score-wrap{
    display:grid;
    grid-template-columns:110px 1fr;
    gap:18px;
    align-items:center;
}

.score{
    width:110px;
    height:110px;
    border-radius:50%;
    display:grid;
    place-items:center;
    border:8px solid var(--border);
    font-size:30px;
    font-weight:900;
}

.score.minimal,
.score.low{
    border-color:var(--low);
}

.score.medium{
    border-color:var(--medium);
}

.score.high{
    border-color:var(--high);
}

.score.critical,
.score.invalid{
    border-color:var(--critical);
}

.risk-name{
    font-size:22px;
    font-weight:850;
    text-transform:capitalize;
}

.muted{
    color:var(--muted);
}

.count-grid{
    margin-top:20px;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:9px;
}

.metric{
    border:1px solid var(--border);
    border-radius:12px;
    padding:11px;
    background:#101025;
}

.metric strong{
    display:block;
    font-size:20px;
}

.metric span{
    color:var(--muted);
    font-size:12px;
}

.notice{
    margin-top:14px;
    padding:12px 13px;
    border:1px solid var(--border);
    border-radius:12px;
    color:var(--muted);
    font-size:12px;
    line-height:1.5;
}

.results{
    margin-top:20px;
}

.results-head{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:12px;
    margin-bottom:12px;
}

.results-head h2{
    margin:0;
}

.findings{
    display:grid;
    gap:10px;
}

.finding{
    border:1px solid var(--border);
    border-radius:14px;
    padding:16px;
    background:var(--surface);
}

.finding-top{
    display:flex;
    gap:10px;
    align-items:center;
    justify-content:space-between;
}

.finding-code{
    color:var(--muted);
    font-family:monospace;
    font-size:12px;
}

.badge{
    display:inline-flex;
    align-items:center;
    padding:5px 8px;
    border-radius:999px;
    font-size:11px;
    font-weight:900;
    text-transform:uppercase;
    border:1px solid currentColor;
}

.badge.critical{
    color:var(--critical);
}

.badge.high{
    color:var(--high);
}

.badge.medium{
    color:var(--medium);
}

.badge.low{
    color:var(--low);
}

.badge.info{
    color:var(--info);
}

.badge.error{
    color:var(--critical);
}

.finding h3{
    margin:12px 0 8px;
    font-size:16px;
}

.path{
    display:block;
    color:#c9c7ff;
    word-break:break-word;
    font-family:monospace;
    font-size:12px;
    margin-bottom:9px;
}

.finding p{
    margin:0;
    color:var(--muted);
    line-height:1.6;
}

.recommendation{
    margin-top:10px!important;
    color:#d7d7ea!important;
}

.empty{
    padding:30px;
    border:1px dashed var(--border);
    border-radius:14px;
    text-align:center;
    color:var(--muted);
}

.content{
    margin:60px auto;
}

.content-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:16px;
}

.info-card{
    padding:23px;
}

.info-card h2,
.info-card h3{
    margin-top:0;
}

.info-card p,
.info-card li{
    color:var(--muted);
    line-height:1.72;
}

pre.example{
    margin:0;
    white-space:pre-wrap;
    overflow:auto;
    padding:18px;
    border-radius:12px;
    background:#0c0c1a;
    border:1px solid var(--border);
    color:#e5e5f8;
    font-size:12px;
}

.home-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:15px;
    margin-top:28px;
}

.tool-card{
    display:block;
    padding:20px;
    text-decoration:none;
}

.tool-card:hover{
    border-color:#5b5b89;
    transform:translateY(-2px);
}

.tool-card h2{
    margin:0 0 8px;
    font-size:17px;
}

.tool-card p{
    margin:0;
    color:var(--muted);
    line-height:1.55;
}

.ready{
    color:#7ee2a8;
    font-size:11px;
    font-weight:800;
    text-transform:uppercase;
    letter-spacing:.06em;
}

.planned{
    color:#8888a5;
    font-size:11px;
    font-weight:800;
    text-transform:uppercase;
    letter-spacing:.06em;
}

.footer{
    margin-top:65px;
    padding:28px 0;
    border-top:1px solid var(--border);
    color:var(--muted);
    font-size:13px;
}

.footer-row{
    display:flex;
    justify-content:space-between;
    gap:16px;
    flex-wrap:wrap;
}

.footer a{
    color:var(--muted);
}

.hidden{
    display:none!important;
}

@media(max-width:850px){
    .tool-layout{
        grid-template-columns:1fr;
    }

    .home-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}

@media(max-width:620px){
    .shell{
        width:min(100% - 22px,1180px);
    }

    .hero{
        padding:42px 0 24px;
    }

    .hero p{
        font-size:16px;
    }

    .home-grid,
    .content-grid{
        grid-template-columns:1fr;
    }

    textarea{
        min-height:390px;
        padding:14px;
    }

    .score-wrap{
        grid-template-columns:86px 1fr;
    }

    .score{
        width:86px;
        height:86px;
        font-size:24px;
    }

    .editor-head,
    .results-head{
        align-items:flex-start;
        flex-direction:column;
    }

    .editor-actions{
        width:100%;
    }

    .editor-actions .btn{
        flex:1;
    }
}


/* =========================================================
   MCP TOOLKIT PHASE 5 NAVIGATION
   ========================================================= */

.site-nav{
    border-top:1px solid var(--border);
    border-bottom:1px solid var(--border);
    background:rgba(9,9,22,.72);
    backdrop-filter:blur(12px);
    -webkit-backdrop-filter:blur(12px);
}

.site-nav-inner{
    min-height:48px;
    display:flex;
    align-items:center;
    gap:8px;
    overflow-x:auto;
    scrollbar-width:none;
}

.site-nav-inner::-webkit-scrollbar{
    display:none;
}

.site-nav a{
    flex:0 0 auto;
    display:inline-flex;
    align-items:center;
    min-height:34px;
    padding:7px 11px;
    border-radius:9px;
    color:var(--muted);
    text-decoration:none;
    font-size:13px;
    font-weight:700;
}

.site-nav a:hover{
    color:var(--text);
    background:var(--surface2);
}

.breadcrumbs{
    display:flex;
    flex-wrap:wrap;
    gap:7px;
    margin:22px 0 0;
    color:var(--muted);
    font-size:13px;
}

.breadcrumbs a{
    color:var(--muted);
    text-decoration:none;
}

.breadcrumbs a:hover{
    color:var(--text);
}

.category-hero{
    padding:58px 0 30px;
}

.category-hero h1{
    margin:0 0 16px;
    font-size:clamp(36px,6vw,64px);
    letter-spacing:-.04em;
    line-height:1.04;
}

.category-hero p{
    max-width:800px;
    color:var(--muted);
    line-height:1.75;
    font-size:17px;
}

.category-grid{
    display:grid;
    grid-template-columns:
        repeat(3,minmax(0,1fr));
    gap:15px;
}

.category-card{
    display:block;
    padding:22px;
    text-decoration:none;
}

.category-card:hover{
    border-color:#5b5b89;
    transform:translateY(-2px);
}

.category-card h2{
    margin:8px 0 9px;
    font-size:18px;
}

.category-card p{
    margin:0;
    color:var(--muted);
    line-height:1.6;
}

.tool-count{
    display:inline-flex;
    padding:5px 8px;
    border:1px solid var(--border);
    border-radius:999px;
    color:var(--muted);
    font-size:11px;
    font-weight:800;
}

.seo-copy{
    margin-top:38px;
}

.seo-copy h2{
    margin-top:0;
}

.seo-copy p,
.seo-copy li{
    color:var(--muted);
    line-height:1.75;
}

.tool-directory-intro{
    margin-bottom:24px;
}

@media(max-width:850px){
    .category-grid{
        grid-template-columns:
            repeat(2,minmax(0,1fr));
    }
}

@media(max-width:620px){
    .category-grid{
        grid-template-columns:1fr;
    }

    .site-nav-inner{
        padding:4px 0;
    }

    .category-hero{
        padding:38px 0 22px;
    }
}
