*{box-sizing:border-box}
:root{
    --primary:#4f46e5;
    --primary-dark:#3730a3;
    --navy:#10182b;
    --bg:#f5f7fb;
    --text:#172033;
    --muted:#7b8496;
    --border:#e7eaf1;
    --white:#fff;
}
html,body{margin:0;padding:0}
body{font-family:Inter,Arial,Helvetica,sans-serif;background:var(--bg);color:var(--text)}
a{text-decoration:none;color:inherit}
button,input,select{font:inherit}
.app-shell{min-height:100vh;display:flex}
.sidebar{width:240px;position:fixed;inset:0 auto 0 0;background:var(--navy);color:#fff;padding:24px 15px;display:flex;flex-direction:column;z-index:20}
.sidebar-brand{display:flex;gap:12px;align-items:center;padding:4px 9px 28px;border-bottom:1px solid rgba(255,255,255,.08)}
.sidebar-brand strong{display:block;font-size:15px;letter-spacing:.3px}
.sidebar-brand small{display:block;color:#9ca7bb;margin-top:4px;font-size:11px}
.brand-square{width:42px;height:42px;border-radius:11px;background:#554ce8;display:grid;place-items:center;font-size:21px}
.sidebar-label{font-size:10px;color:#758096;font-weight:800;letter-spacing:.7px;margin:26px 10px 8px}
.nav-item{display:flex;gap:12px;align-items:center;color:#c7cede;padding:11px 12px;border-radius:8px;font-size:13px;font-weight:600;margin:3px 0}
.nav-item span{width:18px;text-align:center}
.nav-item:hover,.nav-item.active{background:#222d45;color:#fff}
.nav-item.active{box-shadow:inset 3px 0 0 #6d66ff}
.sidebar-bottom{margin-top:auto;border-top:1px solid rgba(255,255,255,.08);padding-top:12px}
.logout-link{color:#ff7184}
.main-shell{margin-left:240px;width:calc(100% - 240px);min-height:100vh}
.topbar{height:76px;background:#fff;border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 30px}
.topbar h1{font-size:20px;margin:0}
.top-user{display:flex;align-items:center;gap:12px;text-align:right}
.top-user strong{display:block;font-size:13px}
.top-user small{display:block;color:var(--muted);font-size:11px;margin-top:3px}
.avatar{width:38px;height:38px;border-radius:50%;background:#eef0ff;display:grid;place-items:center}
.content{padding:30px;max-width:1400px;margin:auto}
.hero{background:linear-gradient(110deg,#4f46e5,#4338ca);color:#fff;border-radius:18px;padding:27px 30px;display:flex;align-items:center;justify-content:space-between;overflow:hidden;position:relative}
.hero h2{font-size:23px;margin:0 0 8px}
.hero p{margin:0;opacity:.88;font-size:13px}
.hero-pattern{font-size:90px;opacity:.12}
.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:18px;margin:28px 0}
.stat-card{background:#fff;border:1px solid var(--border);border-radius:16px;padding:20px;display:flex;gap:15px;align-items:center}
.stat-icon{width:50px;height:50px;border-radius:13px;display:grid;place-items:center;font-size:20px;font-weight:700}
.stat-icon.purple{background:#eef0ff;color:#4f46e5}
.stat-icon.blue{background:#eaf4ff;color:#2563eb}
.stat-icon.green{background:#eafaf2;color:#059669}
.stat-icon.orange{background:#fff5e8;color:#ea580c}
.stat-card small{display:block;color:var(--muted);font-size:10px;font-weight:800}
.stat-card strong{display:block;font-size:28px;margin-top:5px}
.panel{background:#fff;border:1px solid var(--border);border-radius:16px;padding:24px;margin-top:20px}
.panel-title{display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--border);padding-bottom:16px;margin-bottom:18px}
.panel h3{margin:0;font-size:17px}
.panel-title p{margin:5px 0 0;color:var(--muted);font-size:12px}
.steps{display:grid;gap:13px}
.steps div{display:flex;align-items:center;gap:12px;color:#566176;font-size:13px}
.steps b{width:24px;height:24px;border-radius:50%;background:#e9ebff;color:#4f46e5;display:grid;place-items:center;font-size:11px}
.page-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}
.page-head h2{margin:0 0 5px;font-size:20px}
.page-head p{margin:0;color:var(--muted);font-size:13px}
.btn{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:9px;padding:10px 15px;font-size:13px;font-weight:700;cursor:pointer}
.btn-primary{background:var(--primary);color:#fff}
.btn-primary:hover{background:var(--primary-dark)}
.btn-light{background:#f1f3f8;color:#435069}
.btn-sm{padding:7px 10px;font-size:11px}
.btn-block{width:100%}
.table-wrap{overflow:auto}
table{width:100%;border-collapse:collapse;font-size:12px}
th{background:#f7f8fb;color:#728098;font-size:10px;text-align:left;padding:12px;border-bottom:1px solid var(--border)}
td{padding:13px 12px;border-bottom:1px solid #eef0f4}
.empty{text-align:center;color:var(--muted);padding:35px}
.badge{display:inline-block;padding:5px 9px;border-radius:999px;font-size:10px;font-weight:800}
.badge-green{background:#e9f9f0;color:#087f4e}
.badge-red{background:#fff0f2;color:#c92a45}
.form-panel{max-width:850px}
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-bottom:20px}
.form-group.full{grid-column:1/-1}
.form-group label{display:block;font-size:12px;font-weight:800;margin-bottom:7px}
.form-group input,.form-group select,.login-card input{width:100%;border:1px solid #dce1ea;border-radius:9px;padding:12px 13px;outline:0;background:#fff}
.form-group input:focus,.form-group select:focus,.login-card input:focus{border-color:var(--primary);box-shadow:0 0 0 3px rgba(79,70,229,.09)}
.alert{padding:11px 13px;border-radius:9px;font-size:12px;margin-bottom:17px}
.alert-danger{background:#fff0f2;border:1px solid #fecdd3;color:#be123c}
.login-page{min-height:100vh;background:linear-gradient(135deg,#f5f7fb,#eef0ff);display:grid;place-items:center}
.login-shell{width:min(420px,92%);padding:30px 0}
.login-brand{text-align:center;margin-bottom:20px}
.brand-icon{
    width:72px;
    height:72px;
    margin:0 auto 12px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:transparent;
    border-radius:16px;
    overflow:hidden;
    box-shadow:none;
}

.brand-icon img{
    width:72px;
    height:72px;
    max-width:100%;
    max-height:100%;
    object-fit:contain;
    display:block;
}
.login-brand h1{margin:13px 0 5px;font-size:24px}
.login-brand p{margin:0;color:var(--muted);font-size:13px}
.login-card{background:#fff;border:1px solid var(--border);border-radius:18px;padding:28px;box-shadow:0 18px 45px rgba(20,30,60,.08)}
.login-title h2{margin:0 0 5px;font-size:18px}
.login-title p{margin:0 0 22px;color:var(--muted);font-size:12px}
.login-card label{display:block;font-size:12px;font-weight:800;margin:0 0 7px}
.login-card input{margin-bottom:16px}
.login-note{text-align:center;color:#8a94a6;font-size:10px;margin-top:17px}
.copyright{text-align:center;color:#9aa3b4;font-size:11px;margin-top:15px}
@media(max-width:1000px){
    .stats-grid{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:760px){
    .sidebar{width:210px}
    .main-shell{margin-left:210px;width:calc(100% - 210px)}
    .content{padding:20px}
    .topbar{padding:0 20px}
    .form-grid{grid-template-columns:1fr}
    .form-group.full{grid-column:auto}
}
@media(max-width:560px){
    .sidebar{position:static;width:100%;min-height:auto}
    .app-shell{display:block}
    .main-shell{margin:0;width:100%}
    .stats-grid{grid-template-columns:1fr}
    .page-head{align-items:flex-start;gap:12px;flex-direction:column}
}

textarea{width:100%;border:1px solid #dce1ea;border-radius:9px;padding:12px 13px;resize:vertical;outline:0;font:inherit}
textarea:focus{border-color:var(--primary);box-shadow:0 0 0 3px rgba(79,70,229,.09)}
.alert-success{background:#ecfdf5;border:1px solid #bbf7d0;color:#047857}
.text-link{color:var(--primary);font-weight:700}
.muted{color:var(--muted);font-size:12px}
.two-col{display:grid;grid-template-columns:minmax(280px,.8fr) minmax(0,1.6fr);gap:20px}
.sub-panel{background:#f8f9fc;border:1px solid var(--border);border-radius:12px;padding:18px}
.sub-panel h4{margin:0 0 15px}
.form-group{margin-bottom:15px}
.btn-danger{background:#fff0f2;color:#d92d4b}
.select-top{min-width:220px;padding:10px 13px;border:1px solid #dce1ea;border-radius:9px;background:#fff;color:#344054}
.socio-table select{width:150px;padding:8px;border:1px solid #dce1ea;border-radius:7px;background:#fff}
.metric-blue{color:#4f46e5;font-weight:800}.metric-red{color:#e11d48;font-weight:800}
.sociogram-canvas{height:600px;background:#f8f9fc;border-radius:13px;overflow:hidden}
.sociogram-canvas svg{width:100%;height:100%}
.edge-choice{stroke:#64748b;stroke-width:1.5;opacity:.55}
.edge-reject{stroke:#ef476f;stroke-width:1.5;stroke-dasharray:6 5;opacity:.5}
.node-number{font:700 13px Arial;fill:#172033}
.node-name{font:600 11px Arial;fill:#566176}
.graph-legend{display:flex;gap:18px;flex-wrap:wrap;font-size:12px;color:#667085;margin-bottom:15px}
.dot{display:inline-block;width:10px;height:10px;border-radius:50%;margin-right:5px}.male{background:#1da1e2}.female{background:#f472b6}
.reject-line{color:#e11d48}
.analysis-grid{display:grid;grid-template-columns:1fr 1fr;gap:20px}
.analysis-card{border-radius:16px;padding:22px;border:1px solid var(--border);background:#fff}
.analysis-card h3{margin:0 0 18px;font-size:16px}
.analysis-card.popular{background:#fffaf0;border-color:#fde68a}.analysis-card.isolated{background:#fff5f6;border-color:#fecdd3}
.analysis-card p{font-size:13px;color:#566176}
.chips{display:flex;flex-wrap:wrap;gap:8px}.chip{display:inline-block;padding:7px 11px;border-radius:999px;font-size:12px;font-weight:700}.chip-gold{background:#fef3c7;color:#a16207}.chip-red{background:#ffe4e6;color:#be123c}
.recommendation{background:#f5f8ff;border-color:#dbe5ff}.recommendation ol{color:#566176;font-size:13px;line-height:1.7}
@media(max-width:850px){.two-col,.analysis-grid{grid-template-columns:1fr}.socio-table select{width:120px}}

/* =========================================================
   MODERN UI - KELOLA KELAS & SISWA
   ========================================================= */
.kelas-page{max-width:1380px;margin:0 auto;padding-bottom:40px}
.kelas-page-head{display:flex;justify-content:space-between;align-items:center;gap:24px;margin-bottom:24px}
.eyebrow{font-size:10px;letter-spacing:1.1px;font-weight:800;color:#635bff;margin-bottom:7px}
.kelas-page-head h2{font-size:25px;margin:0 0 6px;letter-spacing:-.4px}
.kelas-page-head p{margin:0;color:#7b8496;font-size:13px}
.school-mini{display:flex;align-items:center;gap:11px;background:#fff;border:1px solid #e7eaf1;padding:10px 14px;border-radius:12px;box-shadow:0 3px 12px rgba(16,24,40,.035)}
.school-mini-icon{width:38px;height:38px;border-radius:10px;background:#eef0ff;display:grid;place-items:center;font-size:17px}
.school-mini span{display:block;color:#98a2b3;font-size:10px;margin-bottom:2px}
.school-mini strong{font-size:12px}

.modern-alert{display:flex;align-items:center;gap:10px;border-radius:12px;padding:12px 15px;margin:0 0 18px;font-size:12px}
.modern-alert>span{font-weight:900;font-size:15px}
.modern-alert.danger{background:#fff5f6;color:#be123c;border:1px solid #fecdd3}
.modern-alert.success{background:#effcf5;color:#087f4e;border:1px solid #bbf7d0}

.empty-state-card{background:#fff;border:1px solid #e7eaf1;border-radius:18px;padding:55px 25px;text-align:center;box-shadow:0 5px 20px rgba(16,24,40,.035)}
.empty-state-icon{width:58px;height:58px;margin:0 auto 14px;border-radius:16px;background:#eef0ff;display:grid;place-items:center;font-size:25px}
.empty-state-card h3{margin:0 0 7px;font-size:18px}.empty-state-card p{margin:0 auto 20px;max-width:460px;color:#7b8496;font-size:13px}

.kelas-stats{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin-bottom:18px}
.kelas-stat{background:#fff;border:1px solid #e7eaf1;border-radius:15px;padding:16px 18px;display:flex;align-items:center;gap:13px}
.kelas-stat-icon{width:43px;height:43px;border-radius:12px;display:grid;place-items:center;font-weight:900;font-size:19px}
.kelas-stat-icon.purple{background:#eeefff;color:#4f46e5}.kelas-stat-icon.blue{background:#eaf5ff;color:#1677d2}.kelas-stat-icon.green{background:#eafaf2;color:#059669}
.kelas-stat span{display:block;font-size:10px;color:#8b95a7;font-weight:700;text-transform:uppercase;letter-spacing:.3px}.kelas-stat strong{display:block;font-size:18px;margin-top:4px}

.kelas-top-grid{display:grid;grid-template-columns:310px minmax(0,1fr);gap:18px;align-items:start}
.modern-card{background:#fff;border:1px solid #e7eaf1;border-radius:17px;box-shadow:0 4px 18px rgba(16,24,40,.035);overflow:hidden}
.add-class-card{padding:21px}
.card-heading{display:flex;align-items:center;gap:11px;margin-bottom:20px}
.card-heading-inline{justify-content:space-between;align-items:flex-start;padding:20px 21px 15px;margin:0;border-bottom:1px solid #eef0f4}
.heading-icon{width:38px;height:38px;border-radius:11px;display:grid;place-items:center;font-size:18px;font-weight:800;flex:0 0 auto}
.heading-icon.purple{background:#eeefff;color:#4f46e5}.heading-icon.blue{background:#eaf5ff;color:#1677d2}
.card-heading h3{margin:0;font-size:15px}.card-heading p{margin:4px 0 0;color:#8a94a6;font-size:11px;line-height:1.4}
.count-pill,.list-info{background:#f0f1ff;color:#4f46e5;padding:6px 10px;border-radius:999px;font-size:10px;font-weight:800;white-space:nowrap}

.modern-form-group{margin-bottom:14px}.modern-form-group label{display:block;font-size:11px;font-weight:800;color:#475467;margin-bottom:6px}
.modern-form-group input{width:100%;border:1px solid #dfe3eb;border-radius:9px;padding:11px 12px;background:#fff;outline:none;font-size:12px;transition:.18s}
.modern-form-group input:focus{border-color:#6258f5;box-shadow:0 0 0 3px rgba(79,70,229,.08)}

.class-list-card{min-width:0}
.modern-table-wrap{overflow:auto}
.modern-table{width:100%;border-collapse:collapse;font-size:11px}
.modern-table th{background:#fafbfc;color:#8a94a6;font-size:9px;letter-spacing:.3px;font-weight:800;padding:11px 12px;border-bottom:1px solid #edf0f4;white-space:nowrap}
.modern-table td{padding:12px;border-bottom:1px solid #f0f2f5;vertical-align:middle}
.modern-table tbody tr:last-child td{border-bottom:0}.modern-table tbody tr:hover{background:#fafbff}.modern-table tbody tr.row-active{background:#f7f7ff}
.number-badge{width:27px;height:27px;border-radius:8px;background:#f3f4f7;display:inline-grid;place-items:center;color:#667085;font-size:10px;font-weight:800}
.class-name{font-weight:800;color:#252b3a}.class-name:hover{color:#4f46e5}.year-text{color:#667085}.student-count{font-size:10px;color:#667085}
.action-group{display:flex;gap:6px;align-items:center;white-space:nowrap}.action-group form{margin:0}
.action-btn{border:0;border-radius:8px;padding:7px 9px;font-size:10px;font-weight:800;cursor:pointer}
.action-btn.manage{background:#eef0ff;color:#4f46e5}.action-btn.manage:hover{background:#e2e4ff}
.action-btn.delete{background:#fff1f3;color:#d92d4b}.action-btn.delete:hover{background:#ffe3e7}
.modern-empty{text-align:center!important;color:#98a2b3!important;padding:32px!important}.modern-empty.large{padding:55px!important}

.students-card{margin-top:18px}
.students-header{display:flex;justify-content:space-between;align-items:center;padding:20px 21px;border-bottom:1px solid #edf0f4}
.students-title{display:flex;align-items:center;gap:12px}
.class-avatar{width:45px;height:45px;border-radius:13px;background:linear-gradient(135deg,#5b55ef,#4038ca);color:#fff;display:grid;place-items:center;font-weight:900;font-size:13px;box-shadow:0 7px 15px rgba(79,70,229,.16)}
.students-kicker{font-size:9px;color:#7c86a0;font-weight:800;letter-spacing:.8px;margin-bottom:3px}
.students-title h3{margin:0;font-size:17px}.students-title p{margin:4px 0 0;color:#8b95a7;font-size:11px}.students-title p span{padding:0 4px}
.students-total{text-align:center;background:#eefaf4;border-radius:11px;padding:8px 14px;min-width:60px}.students-total strong{display:block;color:#087f4e;font-size:17px}.students-total span{font-size:9px;color:#4d9273}
.students-layout{display:grid;grid-template-columns:285px minmax(0,1fr);gap:0}
.student-form-box{background:#fafbfc;border-right:1px solid #edf0f4;padding:20px}
.student-form-title{display:flex;gap:10px;align-items:center;margin-bottom:18px}.student-form-title h4,.student-list-head h4{margin:0;font-size:14px}.student-form-title p,.student-list-head p{margin:4px 0 0;color:#8a94a6;font-size:10px;line-height:1.4}
.student-list-box{min-width:0;padding:20px}.student-list-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}
.gender-options{display:grid;grid-template-columns:1fr 1fr;gap:7px}
.gender-option{border:1px solid #dfe3eb;border-radius:9px;padding:9px 8px;font-size:10px;color:#667085;cursor:pointer;background:#fff}
.gender-option input{margin-right:4px}.gender-option span{font-weight:900;color:#4f46e5}
.student-name-cell{display:flex;align-items:center;gap:9px}.student-avatar{width:31px;height:31px;border-radius:9px;display:grid;place-items:center;font-size:10px;font-weight:900}
.student-avatar.male{background:#eaf5ff;color:#1677d2}.student-avatar.female{background:#fff0f7;color:#db4b94}
.gender-badge{display:inline-block;padding:5px 8px;border-radius:7px;font-size:9px;font-weight:800}
.gender-badge.male{background:#eaf5ff;color:#1677d2}.gender-badge.female{background:#fff0f7;color:#db4b94}
.icon-delete{border:0;background:#fff0f2;color:#e11d48;width:30px;height:30px;border-radius:8px;cursor:pointer;font-size:13px}
.icon-delete:hover{background:#ffe2e7}

@media(max-width:1050px){
    .kelas-top-grid{grid-template-columns:1fr}
    .students-layout{grid-template-columns:1fr}
    .student-form-box{border-right:0;border-bottom:1px solid #edf0f4}
}
@media(max-width:700px){
    .kelas-page-head{align-items:flex-start;flex-direction:column}.school-mini{width:100%}
    .kelas-stats{grid-template-columns:1fr}
    .students-header{align-items:flex-start}.students-total{margin-left:10px}
}

/* TABULASI & INDEKS MODERN */
.tabulasi-page{max-width:1380px;margin:0 auto;padding-bottom:40px}
.tabulasi-head{align-items:flex-end}
.tabulasi-actions{display:flex;align-items:center;gap:9px}
.tabulasi-actions form{margin:0}
.btn-print{background:#172033!important;color:#fff!important;border:0!important;text-decoration:none!important;padding:10px 14px!important;border-radius:9px!important;font-size:11px!important;font-weight:800!important;white-space:nowrap}
.btn-print:hover{background:#0f172a!important}
.tabulasi-info-grid{display:grid;grid-template-columns:2fr 1fr 1.2fr 1fr;gap:12px;margin-bottom:17px}
.info-card{background:#fff;border:1px solid #e7eaf1;border-radius:12px;padding:13px 15px;box-shadow:0 3px 14px rgba(16,24,40,.025)}
.info-label{display:block;color:#98a2b3;font-size:8px;font-weight:800;letter-spacing:.55px;margin-bottom:5px}
.info-card strong{font-size:12px;color:#252b3a}
.tabulasi-panel{overflow:hidden}
.panel-heading-modern{display:flex;align-items:center;justify-content:space-between;padding:18px 20px;border-bottom:1px solid #edf0f4}
.panel-heading-modern h3{margin:0;font-size:15px}.panel-heading-modern p{margin:4px 0 0;color:#8a94a6;font-size:10px}
.data-pill{background:#eefaf4;color:#087f4e;border-radius:999px;padding:6px 10px;font-size:9px;font-weight:800}
.tabulasi-table th{text-align:center}.tabulasi-table td{text-align:center}.tabulasi-table td:nth-child(2){text-align:left}
.tabulasi-note{display:flex;flex-wrap:wrap;gap:14px;padding:13px 20px;background:#fafbfc;border-top:1px solid #edf0f4;color:#7b8496;font-size:9px}
.tabulasi-note strong{color:#475467}
@media(max-width:900px){
 .tabulasi-info-grid{grid-template-columns:1fr 1fr}
 .tabulasi-head{align-items:flex-start}
 .tabulasi-actions{width:100%;flex-wrap:wrap}
}
@media(max-width:600px){.tabulasi-info-grid{grid-template-columns:1fr}.tabulasi-actions form{flex:1}.tabulasi-actions .select-top{width:100%}}

/* SOSIOGRAM FINAL MODERN */
.sosiogram-page-final{max-width:1380px;margin:0 auto;padding-bottom:42px}
.sog-topbar{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;margin-bottom:18px}
.sog-topbar h2{margin:0 0 4px;font-size:24px;letter-spacing:-.35px}
.sog-topbar p{margin:0;color:#7b8496;font-size:12px}
.sog-actions{display:flex;align-items:center;gap:9px}
.sog-actions form{margin:0}
.sog-print-btn{background:#172033!important;color:#fff!important;border:0!important;border-radius:9px!important;padding:10px 14px!important;font-size:11px!important;font-weight:800!important;text-decoration:none!important;white-space:nowrap}
.sog-print-btn:hover{background:#0f172a!important}

.sog-summary-grid{display:grid;grid-template-columns:2fr 1fr 1.2fr 1fr;gap:12px;margin-bottom:16px}
.sog-summary-card{background:#fff;border:1px solid #e7eaf1;border-radius:13px;padding:14px 16px;box-shadow:0 3px 14px rgba(16,24,40,.035)}
.sog-summary-card span{display:block;font-size:8px;font-weight:800;letter-spacing:.55px;color:#98a2b3;text-transform:uppercase;margin-bottom:6px}
.sog-summary-card strong{display:block;color:#252b3a;font-size:12px}
.sog-summary-card.accent{background:linear-gradient(135deg,#f5f3ff,#fff);border-color:#ddd8ff}
.sog-summary-card.accent strong{color:#5146e5}

.sog-card-final{overflow:hidden}
.sog-card-head-final{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;padding:19px 21px 15px;border-bottom:1px solid #edf0f4}
.sog-card-head-final h3{margin:0;font-size:16px}
.sog-card-head-final p{margin:5px 0 0;color:#8a94a6;font-size:10px}
.sog-legend-final{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:14px;padding-top:2px}
.sog-legend-final span{display:inline-flex;align-items:center;gap:6px;color:#667085;font-size:10px;font-weight:700;white-space:nowrap}
.sog-legend-final .dot{width:9px;height:9px;border-radius:50%;display:inline-block}
.sog-legend-final .dot.male{background:#1597db}
.sog-legend-final .dot.female{background:#ec4899}
.sog-legend-final .line{display:inline-block;width:28px;border-top:2.5px solid #4f46e5}
.sog-legend-final .line.reject{border-top-color:#e11d48;border-top-style:dashed}

.sog-reading-guide{display:flex;align-items:center;gap:10px;margin:14px 18px 0;padding:10px 12px;border-radius:10px;background:#f7f8fc;color:#667085;font-size:9px}
.sog-reading-guide .guide-icon{width:20px;height:20px;border-radius:50%;display:grid;place-items:center;background:#ecebff;color:#5146e5;font-weight:900}
.sog-reading-guide div{display:flex;flex-wrap:wrap;gap:10px}
.sog-reading-guide strong{color:#344054}
.choice-label{color:#4f46e5}
.reject-label{color:#e11d48}

.sociogram-canvas-final{height:620px;margin:14px;border:1px solid #e4e8ef;border-radius:14px;background:radial-gradient(circle at center,#fff 0%,#fafbfe 63%,#f5f7fa 100%);overflow:hidden;position:relative}
.sog-svg-final{display:block;width:100%;height:100%;overflow:hidden}
.sog-edge{fill:none;stroke-linecap:round;vector-effect:non-scaling-stroke}
.sog-edge.choice{stroke:#4f46e5;stroke-width:2.7;opacity:.82}
.sog-edge.reject{stroke:#e11d48;stroke-width:2.5;stroke-dasharray:8 6;opacity:.84}
.sog-node-final{cursor:default}
.sog-node-number{font:800 12px Arial,sans-serif;fill:#172033}
.sog-node-name{font:700 11px Arial,sans-serif;fill:#344054}
.graph-empty-final{height:100%;display:grid;place-items:center;color:#98a2b3;font-size:12px}
.sog-no-data{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-height:180px;color:#98a2b3;text-align:center}
.sog-no-data div{font-size:30px;color:#c4c8d0}
.sog-no-data strong{font-size:13px;color:#667085}
.sog-no-data span{font-size:10px}

.sog-empty-card{text-align:center;padding:70px 20px}
.sog-empty-icon{font-size:40px;color:#5146e5;margin-bottom:8px}
.sog-empty-card h3{margin:0 0 5px}
.sog-empty-card p{margin:0;color:#8a94a6}

@media(max-width:1000px){
    .sog-summary-grid{grid-template-columns:1fr 1fr}
    .sog-topbar{align-items:flex-start;flex-direction:column}
    .sog-actions{width:100%}
}
@media(max-width:760px){
    .sog-summary-grid{grid-template-columns:1fr}
    .sog-actions{flex-wrap:wrap}
    .sog-actions form{flex:1;min-width:180px}
    .sog-card-head-final{flex-direction:column}
    .sog-legend-final{justify-content:flex-start}
    .sociogram-canvas-final{height:520px;margin:10px}
}