* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    background: radial-gradient(circle at 20% 20%, #0f1620, #0b0f14 60%);
    color: #d1d5db;
    overflow: hidden;
}

body::before {
    content: "";
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(37,99,235,0.08), transparent 70%);
    animation: ambientMove 12s ease-in-out infinite alternate;
}

@keyframes ambientMove {
    from { transform: translate(-40px, -30px); }
    to { transform: translate(40px, 30px); }
}

.container {
    width: 520px;
    padding: 50px 45px;
    border-radius: 18px;
    background: #11161c;
    border: 1px solid #1f2933;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.6),
        inset 0 1px 0 rgba(255,255,255,0.02);
    position: relative;
    z-index: 1;
    animation: containerFade 0.8s ease forwards;
    opacity: 0;
    transform: translateY(10px);
}

@keyframes containerFade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1 {
    font-size: 26px;
    margin-bottom: 35px;
    font-weight: 600;
    letter-spacing: 1px;
    color: #f3f4f6;
    position: relative;
}

h1::after {
    content: "";
    display: block;
    height: 2px;
    width: 60px;
    margin-top: 10px;
    background: #2563eb;
    animation: lineExpand 1s ease forwards;
    transform: scaleX(0);
    transform-origin: left;
}

@keyframes lineExpand {
    to { transform: scaleX(1); }
}

input {
    width: 100%;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid #1f2933;
    background: #0f141a;
    color: #e5e7eb;
    font-size: 14px;
    transition: 0.25s ease;
}

input:focus {
    outline: none;
    border-color: #2563eb;
    background: #0c1117;
    box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
    transform: scale(1.01);
}

button {
    width: 100%;
    padding: 16px;
    margin-top: 18px;
    border-radius: 10px;
    border: 1px solid #1f2933;
    background: #1a2129;
    color: #e5e7eb;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s ease;
    position: relative;
    overflow: hidden;
}

button:hover {
    background: #212a33;
    border-color: #2d3742;
    transform: translateY(-2px);
}

button:active {
    transform: scale(0.98);
}

button::after {
    content: "";
    position: absolute;
    width: 120%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.05),
        transparent
    );
    top: 0;
    left: -120%;
    transition: 0.6s ease;
}

button:hover::after {
    left: 120%;
}

#result {
    margin-top: 30px;
}

.result-box {
    padding: 24px;
    border-radius: 12px;
    background: #0f141a;
    border: 1px solid #1f2933;
    animation: resultReveal 0.5s ease forwards;
    opacity: 0;
    transform: translateY(8px);
}

@keyframes resultReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.score {
    margin-top: 14px;
    font-size: 20px;
    font-weight: 600;
    color: #f9fafb;
    position: relative;
}

.score::after {
    content: "";
    display: block;
    height: 6px;
    margin-top: 10px;
    border-radius: 6px;
    background: linear-gradient(90deg, #10b981, #facc15, #ef4444);
    animation: barGlow 2s ease-in-out infinite alternate;
}

@keyframes barGlow {
    from { opacity: 0.7; }
    to { opacity: 1; }
}

.reasons {
    margin-top: 14px;
    font-size: 13px;
    line-height: 1.6;
    color: #9ca3af;
}

.safe {
    border-color: #064e3b;
    background: #0c1512;
    color: #34d399;
}

.warning {
    border-color: #78350f;
    background: #14120c;
    color: #fbbf24;
}

.danger {
    border-color: #7f1d1d;
    background: #150f12;
    color: #f87171;
    animation: dangerPulse 1.8s infinite alternate;
}

@keyframes dangerPulse {
    from { box-shadow: 0 0 10px rgba(239,68,68,0.25); }
    to { box-shadow: 0 0 30px rgba(239,68,68,0.5); }
}