:root {
    --bg-color-1: #0B0E14;
    --bg-color-2: #1A1A24;
    --primary-gold: #D4AF37;
    --secondary-gold: #F3E5AB;
    --accent-red: #8B0000;
    --text-main: #EAEAEA;
    --text-muted: #A0A0A0;
    --font-serif: 'Noto Serif SC', serif;
}

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

body {
    font-family: var(--font-serif);
    background-color: var(--bg-color-1);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
}

.background-animation {
    position: fixed;
    top: -5%;
    left: -5%;
    width: 110vw;
    height: 110vh;
    background: url('bg_v2.png') center/cover no-repeat;
    z-index: -1;
    animation: panBackground 60s ease-in-out infinite;
}

.background-animation::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(11, 14, 20, 0.4) 0%, rgba(11, 14, 20, 0.9) 100%);
    z-index: -1;
}

@keyframes panBackground {
    0% { transform: scale(1) translate(0, 0); }
    50% { transform: scale(1.05) translate(-1%, -1%); }
    100% { transform: scale(1) translate(0, 0); }
}

.container {
    width: 100%;
    max-width: 600px;
    padding: 2rem;
    z-index: 1;
}

header {
    text-align: center;
    margin-bottom: 2.5rem;
}

h1.glow {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-gold);
    text-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
    letter-spacing: 4px;
    margin-bottom: 0.5rem;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    letter-spacing: 2px;
}

.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(212, 175, 55, 0.15);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: all 0.5s ease;
}

.hidden {
    display: none !important;
    opacity: 0;
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1rem;
    color: var(--secondary-gold);
    letter-spacing: 1px;
}

input[type="text"], input[type="date"], input[type="time"] {
    width: 100%;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-main);
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s;
}

input:focus {
    outline: none;
    border-color: var(--primary-gold);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
}

.radio-group {
    display: flex;
    gap: 1.5rem;
}

.radio-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 1.1rem;
}

.radio-label input[type="radio"] {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    margin-right: 8px;
    position: relative;
    transition: all 0.3s;
}

.radio-label input[type="radio"]:checked {
    border-color: var(--primary-gold);
}

.radio-label input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--primary-gold);
    border-radius: 50%;
}

.primary-btn {
    width: 100%;
    padding: 14px;
    margin-top: 1rem;
    background: linear-gradient(135deg, #D4AF37 0%, #AA801E 100%);
    color: #111;
    border: none;
    border-radius: 8px;
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 2px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
}

.secondary-btn {
    width: 100%;
    padding: 12px;
    margin-top: 2rem;
    background: transparent;
    color: var(--primary-gold);
    border: 1px solid var(--primary-gold);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
}

.secondary-btn:hover {
    background: rgba(212, 175, 55, 0.1);
}

.disclaimer {
    margin-top: 1.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.5;
}

.footer-link {
    text-align: center;
    margin-top: 0.8rem;
    font-size: 0.85rem;
}

.footer-link a {
    color: var(--text-muted);
    text-decoration: none;
    font-family: sans-serif;
    letter-spacing: 1px;
    transition: color 0.3s;
}

.footer-link a:hover {
    color: var(--primary-gold);
}

/* Results Section */
.result-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.result-header h2 {
    color: var(--primary-gold);
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.bazi-info {
    font-size: 1.1rem;
    line-height: 1.6;
}

.bazi-info .highlight {
    color: var(--accent-red);
    font-weight: 600;
}

.name-card {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-gold);
    transition: transform 0.3s;
}

.name-card:hover {
    transform: translateX(5px);
    background: rgba(0, 0, 0, 0.3);
}

.name-zh {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--primary-gold);
    margin-bottom: 0.5rem;
    letter-spacing: 8px;
}

.name-pinyin {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-family: sans-serif;
}

.name-meaning {
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-main);
}

@media (max-width: 600px) {
    .container { padding: 1rem; }
    .glass-card { padding: 1.5rem; }
    h1.glow { font-size: 2rem; }
    .background-animation {
        background-image: url('mobile_bg_v2.png');
    }
}
