/* ═══════════════════════════════════════════════
   SOVEREIGN EYE — Security Scanner Styles
   ═══════════════════════════════════════════════ */

.se-main {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 24px 60px;
}

/* ─── Hero ─── */
.se-hero {
    text-align: center;
    padding: 48px 0 32px;
}

.se-label {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #558b2f;
    background: hsl(88, 50%, 93%);
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 16px;
}

.se-hero h1 {
    font-size: 2.4rem;
    font-weight: 800;
    color: #2d2a26;
    margin: 12px 0 8px;
    letter-spacing: -0.02em;
}

.se-subtitle {
    font-size: 1.05rem;
    color: #8a857d;
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ─── Input Panel ─── */
.se-input-panel {
    margin-bottom: 28px;
}

.se-input-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.se-input-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.se-input-icon {
    position: absolute;
    left: 16px;
    font-size: 16px;
    pointer-events: none;
    z-index: 1;
}

.se-url-input {
    width: 100%;
    padding: 14px 16px 14px 44px;
    font-size: 15px;
    font-family: 'SFMono-Regular', 'Consolas', 'Liberation Mono', monospace;
    border: 1.5px solid #e0dcd6;
    border-radius: 10px;
    background: #fffefa;
    color: #2d2a26;
    outline: none;
    transition: border-color 200ms, box-shadow 200ms;
}

.se-url-input:focus {
    border-color: #558b2f;
    box-shadow: 0 0 0 3px hsla(88, 50%, 40%, 0.1);
}

.se-url-input::placeholder {
    color: #bbb7af;
}

.se-scan-btn {
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 700;
    font-family: inherit;
    background: linear-gradient(135deg, #558b2f, #43a047);
    color: #fff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: background 200ms, transform 100ms, box-shadow 200ms;
    white-space: nowrap;
    min-width: 110px;
}

.se-scan-btn:hover {
    background: linear-gradient(135deg, #43a047, #2e7d32);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(85, 139, 47, 0.3);
}

.se-scan-btn:active {
    transform: translateY(0);
}

.se-scan-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.se-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: se-spin 0.6s linear infinite;
    vertical-align: middle;
    margin-right: 4px;
}

@keyframes se-spin {
    to { transform: rotate(360deg); }
}

.se-disclaimer {
    margin-top: 10px;
    font-size: 12px;
    color: #b0a99f;
    text-align: center;
}

/* ─── Grade Panel ─── */
.se-grade-panel {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 28px 32px;
    background: #fffefa;
    border: 1px solid #e8e4de;
    border-radius: 14px;
    margin-bottom: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.se-grade-ring {
    position: relative;
    width: 100px;
    height: 100px;
    flex-shrink: 0;
}

.se-grade-ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.ring-bg {
    fill: none;
    stroke: #f0ece6;
    stroke-width: 8;
}

.ring-fill {
    fill: none;
    stroke: #558b2f;
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 326.7;
    stroke-dashoffset: 326.7;
    transition: stroke-dashoffset 1.2s ease-out, stroke 400ms;
}

.se-grade-letter {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    font-weight: 800;
    color: #2d2a26;
}

.se-grade-info {
    flex: 1;
}

.se-score-label {
    font-size: 12px;
    color: #9e9890;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    margin-bottom: 2px;
}

.se-score-num {
    font-size: 2.2rem;
    font-weight: 800;
    color: #2d2a26;
    line-height: 1.1;
}

.se-meta {
    font-size: 13px;
    color: #8a857d;
    margin-top: 6px;
}

/* ─── Summary counts ─── */
.se-summary {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.se-summary-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
}

.se-tag-critical { background: #fce4ec; color: #c62828; }
.se-tag-high { background: #fff3e0; color: #e65100; }
.se-tag-medium { background: #fff8e1; color: #f9a825; }
.se-tag-low { background: #e8f5e9; color: #2e7d32; }
.se-tag-info { background: #e3f2fd; color: #1565c0; }
.se-tag-pass { background: #e8f5e9; color: #2e7d32; }

/* ─── Findings ─── */
.se-findings {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.se-finding {
    border: 1px solid #e8e4de;
    border-radius: 10px;
    background: #fffefa;
    overflow: hidden;
    transition: box-shadow 200ms;
}

.se-finding:hover {
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

.se-finding-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    cursor: pointer;
    user-select: none;
}

.se-finding-header:hover {
    background: hsl(35, 30%, 98%);
}

.se-severity-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.se-dot-critical { background: #c62828; }
.se-dot-high { background: #e65100; }
.se-dot-medium { background: #f9a825; }
.se-dot-low { background: #66bb6a; }
.se-dot-info { background: #42a5f5; }

.se-finding-title {
    flex: 1;
    font-size: 14px;
    font-weight: 600;
    color: #2d2a26;
}

.se-finding-severity {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 3px 10px;
    border-radius: 6px;
}

.se-sev-critical { background: #fce4ec; color: #c62828; }
.se-sev-high { background: #fff3e0; color: #e65100; }
.se-sev-medium { background: #fff8e1; color: #f9a825; }
.se-sev-low { background: #e8f5e9; color: #2e7d32; }
.se-sev-info { background: #e3f2fd; color: #1565c0; }

.se-finding-chevron {
    font-size: 12px;
    color: #bbb7af;
    transition: transform 200ms;
}

.se-finding.open .se-finding-chevron {
    transform: rotate(90deg);
}

.se-finding-details {
    display: none;
    padding: 0 18px 16px;
    border-top: 1px solid #f0ece6;
}

.se-finding.open .se-finding-details {
    display: block;
}

.se-detail-row {
    margin-top: 10px;
}

.se-detail-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9e9890;
    margin-bottom: 4px;
}

.se-detail-text {
    font-size: 13px;
    color: #5a5650;
    line-height: 1.6;
}

.se-detail-code {
    font-family: 'SFMono-Regular', 'Consolas', monospace;
    font-size: 12px;
    background: #f8f5f0;
    padding: 8px 12px;
    border-radius: 6px;
    color: #558b2f;
    word-break: break-all;
    border: 1px solid #e8e4de;
}

/* ─── Error state ─── */
.se-error {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 20px;
    background: #fff3e0;
    border: 1px solid #ffe0b2;
    border-radius: 10px;
    font-size: 14px;
    color: #e65100;
    margin-top: 20px;
}

/* ─── Empty state ─── */
.se-empty {
    text-align: center;
    padding: 60px 20px;
    color: #8a857d;
}

.se-empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.se-empty h3 {
    font-size: 1.2rem;
    color: #5a5650;
    margin-bottom: 6px;
}

.se-empty p {
    font-size: 14px;
    max-width: 420px;
    margin: 0 auto 20px;
    line-height: 1.5;
}

.se-checks-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.se-check-tag {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    background: hsl(35, 30%, 95%);
    color: #8a857d;
}

/* ─── CTA ─── */
.se-cta {
    text-align: center;
    margin-top: 48px;
    padding: 32px;
    background: hsl(35, 30%, 97%);
    border-radius: 14px;
    border: 1px solid #e8e4de;
}

.se-cta p {
    font-size: 15px;
    color: #5a5650;
    margin-bottom: 16px;
}

.se-cta-btn {
    display: inline-block;
    padding: 12px 28px;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #558b2f, #43a047);
    border-radius: 10px;
    text-decoration: none;
    transition: all 200ms;
}

.se-cta-btn:hover {
    background: linear-gradient(135deg, #43a047, #2e7d32);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(85, 139, 47, 0.3);
    color: #fff;
}

/* ─── Grade Colors ─── */
.grade-a .ring-fill { stroke: #2e7d32; }
.grade-b .ring-fill { stroke: #558b2f; }
.grade-c .ring-fill { stroke: #f9a825; }
.grade-d .ring-fill { stroke: #e65100; }
.grade-f .ring-fill { stroke: #c62828; }

.grade-a .se-grade-letter { color: #2e7d32; }
.grade-b .se-grade-letter { color: #558b2f; }
.grade-c .se-grade-letter { color: #f9a825; }
.grade-d .se-grade-letter { color: #e65100; }
.grade-f .se-grade-letter { color: #c62828; }

/* ─── Responsive ─── */
@media (max-width: 640px) {
    .se-hero h1 { font-size: 1.8rem; }
    .se-input-row { flex-direction: column; }
    .se-grade-panel { flex-direction: column; text-align: center; gap: 16px; padding: 24px 20px; }
    .se-grade-ring { margin: 0 auto; }
    .se-summary { justify-content: center; }
}

/* copy toast (shared) */
.copy-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: #2d2a26;
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    opacity: 0;
    transition: all 300ms ease;
    pointer-events: none;
    z-index: 999;
}

.copy-toast.visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}
