:root {
    --primary-color: #60463B;
    --secondary-color: #856A5D;
    --bg-color: #DFE0E2;
    --accent-color: #D4AF37;
    --text-color: #2c2c2c;
    --white: #ffffff;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    --deep-shadow: 0 15px 45px rgba(0, 0, 0, 0.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background-image: radial-gradient(circle at center, rgba(255,255,255,0.1) 0%, rgba(0,0,0,0.05) 100%);
}

.court-container {
    width: 100%;
    max-width: 600px;
    text-align: center;
}

header {
    margin-bottom: 40px;
}

header h1 {
    font-family: 'Nanum Myeongjo', serif;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 5px;
    letter-spacing: -1px;
}

.subtitle {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--secondary-color);
    font-weight: 700;
}

.screen {
    display: none;
    animation: fadeIn 0.5s ease-out forwards;
}

.screen.active {
    display: block;
}

/* Cards */
.court-card, .result-card {
    background: var(--white);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--deep-shadow);
    border: 1px solid rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
}

.court-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 8px;
    background: var(--primary-color);
}

/* Input Groups */
.input-group {
    text-align: left;
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--primary-color);
    font-size: 0.95rem;
}

textarea {
    width: 100%;
    height: 100px;
    padding: 15px;
    border: 2px solid #eee;
    border-radius: 12px;
    resize: none;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(133, 106, 93, 0.1);
}

.divider {
    margin: 30px 0;
    font-family: 'Nanum Myeongjo', serif;
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--secondary-color);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.divider::before, .divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #eee;
    margin: 0 20px;
}

/* Buttons */
.hammer-btn {
    width: 100%;
    padding: 18px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 0 #3e2d26;
}

.hammer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #3e2d26;
    background-color: #715246;
}

.hammer-btn:active {
    transform: translateY(2px);
    box-shadow: 0 0 0 #3e2d26;
}

.hammer-icon {
    font-size: 1.4rem;
}

.btn-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 30px;
}

.secondary-btn, .accent-btn {
    padding: 15px;
    border-radius: 10px;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.secondary-btn {
    background: #f0f0f0;
    color: #666;
}

.accent-btn {
    background: var(--primary-color);
    color: white;
}

/* Loading Screen */
.loading-content {
    padding: 50px 0;
}

.gavel-animation {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: hammerSwing 0.8s infinite;
}

#loading-text {
    font-weight: 700;
    color: var(--primary-color);
    font-style: italic;
}

/* Result Screen */
.winner-badge {
    display: inline-block;
    background: var(--accent-color);
    color: #000;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: 800;
    margin-bottom: 20px;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
}

.verdict-content h2 {
    font-family: 'Nanum Myeongjo', serif;
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.verdict-body {
    background: #fdfaf5;
    padding: 25px;
    border-radius: 12px;
    border-left: 5px solid var(--secondary-color);
    margin-bottom: 20px;
    text-align: left;
    font-size: 1.1rem;
    color: #444;
}

.punishment {
    padding: 15px;
    background: #fff5f5;
    border-radius: 10px;
    font-size: 1rem;
    color: #d63031;
}

footer {
    margin-top: 40px;
    font-size: 0.8rem;
    color: var(--secondary-color);
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes hammerSwing {
    0% { transform: rotate(0deg); }
    50% { transform: rotate(-45deg); }
    100% { transform: rotate(0deg); }
}

/* Mobile Responsive */
@media (max-width: 480px) {
    header h1 { font-size: 1.8rem; }
    .court-card { padding: 20px; }
    .btn-group { grid-template-columns: 1fr; }
}
