@import url("https://fonts.googleapis.com/css2?family=Gowun+Dodum&family=Gowun+Batang:wght@600;700&display=swap");

:root {
    --ink: #161a22;
    --muted: #5a6275;
    --panel: rgba(255, 255, 255, 0.94);
    --accent: #ff8a5b;
    --accent-dark: #e26a42;
    --accent-2: #6f7bf7;
    --line: rgba(22, 26, 34, 0.12);
}

* {
    box-sizing: border-box;
}

body {
    font-family: "Gowun Dodum", "Gowun Batang", serif;
    color: var(--ink);
    background: radial-gradient(circle at 20% 10%, #ffe0c7, #f6d9ea 42%, #d3e4ff 70%, #c6f0f5);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 48px 20px;
    overflow-x: hidden;
}

h1,
h2,
h3 {
    font-family: "Gowun Batang", serif;
    margin: 0 0 12px;
    letter-spacing: -0.02em;
}

.backdrop {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    width: 360px;
    height: 360px;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.6;
    animation: float 12s ease-in-out infinite;
}

.blob-a {
    background: #ffd29f;
    top: -120px;
    left: -60px;
}

.blob-b {
    background: #9fd3c7;
    bottom: -140px;
    right: -80px;
    animation-delay: 2s;
}

.grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(0, 0, 0, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, 0.04) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.35;
}

.app {
    width: min(860px, 100%);
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.brand {
    text-align: left;
    animation: rise 0.7s ease-out;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.3em;
    font-size: 0.75rem;
    color: var(--muted);
    margin: 0 0 10px;
}

.subhead {
    margin: 0;
    color: var(--muted);
    font-size: 1.02rem;
}

.weather-panel {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.weather-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.weather-body {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 16px;
}

.weather-main {
    background: rgba(255, 255, 255, 0.75);
    border-radius: 18px;
    padding: 18px;
    border: 1px solid rgba(22, 26, 34, 0.08);
}

.weather-status {
    color: var(--muted);
    margin: 0 0 10px;
}

.weather-temp {
    font-size: 2.4rem;
    margin: 0 0 6px;
    font-weight: 700;
}

.weather-summary {
    margin: 0;
    color: var(--muted);
}

.weather-details {
    display: grid;
    gap: 12px;
}

.weather-details div {
    background: rgba(255, 255, 255, 0.7);
    border-radius: 14px;
    padding: 12px 14px;
    border: 1px solid rgba(22, 26, 34, 0.08);
}

.weather-label {
    margin: 0 0 6px;
    font-size: 0.85rem;
    color: var(--muted);
}

.weather-note {
    font-size: 0.85rem;
    color: var(--muted);
    margin: 0;
}

.panel {
    background: var(--panel);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 22px;
    padding: 28px;
    box-shadow: 0 20px 50px rgba(29, 27, 22, 0.16);
    animation: rise 0.8s ease-out;
}

.hero-visual {
    width: 100%;
    height: 180px;
    border-radius: 18px;
    margin: 18px 0 6px;
    background: linear-gradient(135deg, rgba(255, 138, 91, 0.2), rgba(111, 123, 247, 0.2));
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 220'><defs><linearGradient id='g' x1='0' x2='1' y1='0' y2='1'><stop offset='0' stop-color='%23ffc3a0'/><stop offset='1' stop-color='%23c6d4ff'/></linearGradient></defs><rect width='600' height='220' rx='24' fill='url(%23g)'/><path d='M60 150c40-40 90-60 150-50 60 10 90 50 150 30 60-20 120-20 180 10' fill='none' stroke='rgba(255,255,255,0.7)' stroke-width='8' stroke-linecap='round'/><circle cx='110' cy='80' r='34' fill='rgba(255,255,255,0.55)'/><circle cx='480' cy='130' r='46' fill='rgba(255,255,255,0.4)'/><path d='M260 90h160' stroke='rgba(22,26,34,0.25)' stroke-width='6' stroke-linecap='round'/><path d='M300 120l16 16 26-34' stroke='rgba(22,26,34,0.35)' stroke-width='6' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>");
    background-size: cover;
    border: 1px solid rgba(29, 27, 22, 0.08);
}

.rules {
    margin: 16px 0 24px;
    padding-left: 18px;
    color: var(--muted);
}

.rules li {
    margin-bottom: 8px;
}

.quiz-header {
    display: grid;
    gap: 16px;
}

.meta {
    font-size: 0.9rem;
    color: var(--muted);
    margin: 0 0 10px;
}

.progress {
    width: 100%;
    height: 10px;
    background: rgba(29, 27, 22, 0.08);
    border-radius: 999px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    width: 0%;
    transition: width 0.4s ease;
}

.question-visual {
    margin-top: 16px;
    border-radius: 18px;
    border: 1px solid rgba(29, 27, 22, 0.08);
    background: rgba(255, 255, 255, 0.7);
    padding: 14px;
    min-height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.question-visual svg {
    width: 100%;
    max-height: 160px;
}

.btn-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.answer-btn {
    background: #fff;
    border: 1px solid var(--line);
    padding: 14px 16px;
    border-radius: 14px;
    cursor: pointer;
    font-size: 1rem;
    text-align: left;
    transition: transform 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.answer-btn:hover {
    transform: translateY(-2px);
    border-color: rgba(29, 27, 22, 0.3);
    box-shadow: 0 10px 20px rgba(29, 27, 22, 0.12);
}

.answer-btn:disabled {
    cursor: default;
    transform: none;
    box-shadow: none;
}

.answer-btn.selected {
    background: rgba(111, 123, 247, 0.12);
    border-color: rgba(111, 123, 247, 0.6);
    box-shadow: 0 12px 24px rgba(111, 123, 247, 0.2);
}

.primary-btn,
.ghost-btn {
    border: none;
    padding: 12px 22px;
    border-radius: 999px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
}

.primary-btn {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 12px 25px rgba(255, 122, 69, 0.35);
    transition: transform 0.2s ease, background 0.2s ease;
}

.primary-btn:hover {
    transform: translateY(-2px);
    background: var(--accent-dark);
}

.ghost-btn {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--line);
    margin-top: 18px;
}

.ghost-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.score {
    font-size: 1.4rem;
    margin: 12px 0 6px;
}

.result-title {
    margin-top: 4px;
    font-size: 1.2rem;
}

.result-traits {
    margin: 16px 0 22px;
    padding-left: 18px;
    color: var(--muted);
}

.result-traits li {
    margin-bottom: 6px;
}

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

.footer {
    color: var(--muted);
    font-size: 0.9rem;
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%,
    100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(18px);
    }
}

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

    .panel {
        padding: 22px;
    }

    .weather-body {
        grid-template-columns: 1fr;
    }
}
