:root {
    --primary: #FFD500; /* Vibrant HiKorean Yellow */
    --primary-dark: #E6C000;
    --primary-light: #FFF4B3;
    --secondary: #E6C000; /* Darker Yellow instead of Red */
    --dark: #372521; /* Dark Brown from Logo */
    --dark-grey: #4A3A36;
    --text-main: #2C3E50;
    --text-muted: #64748B;
    --bg-main: #F8FAFC;
    --white: #FFFFFF;
    --border: #E2E8F0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: var(--primary);
    --radius-md: 16px;
    --radius-lg: 32px;
    --radius-full: 9999px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    padding: 2rem 1rem;
}

/* Background elements */
.background-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.6;
    animation: float 10s infinite ease-in-out alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, var(--primary-light) 0%, transparent 70%);
}

.blob-2 {
    bottom: -20%;
    right: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(255, 213, 0, 0.2) 0%, transparent 70%);
    animation-delay: -5s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(5%, 5%) scale(1.05); }
}

.container {
    max-width: 800px;
    margin: 0 auto;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 3rem;
    animation: slideDown 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.logo {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -1px;
    display: inline-block;
}

.logo-hi {
    background-color: var(--dark);
    color: var(--primary);
    padding: 0.2rem 0.5rem;
    border-radius: 8px;
    margin-right: 2px;
    display: inline-block;
}

.logo-korean {
    color: var(--primary);
}

.header h1 {
    font-size: 2.2rem;
    color: var(--dark);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.header p {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Form Container */
.form-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Form Sections */
.form-section {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 2px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 3rem 2.5rem;
    box-shadow: var(--shadow-lg);
    animation: fadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.form-section:nth-child(1) { animation-delay: 0.1s; }
.form-section:nth-child(2) { animation-delay: 0.2s; }
.form-section:nth-child(3) { animation-delay: 0.3s; }
.form-section:nth-child(4) { animation-delay: 0.4s; }

.form-section h2 {
    font-size: 1.5rem;
    color: var(--dark);
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--primary);
    display: inline-block;
}

/* Form Groups & Inputs */
.form-group {
    margin-bottom: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-grey);
}

.required {
    color: var(--secondary);
    margin-left: 4px;
}

input[type="text"],
input[type="tel"],
input[type="date"],
select.form-select {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    background-color: var(--white);
    transition: all 0.3s ease;
    outline: none;
}

select.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2em;
    padding-right: 3rem;
    cursor: pointer;
}

input[type="text"]:focus,
input[type="tel"]:focus,
input[type="date"]:focus,
select.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 213, 0, 0.15);
}

input::placeholder {
    color: #A0AEC0;
}

/* Custom Dropdown for Checkboxes */
.custom-dropdown {
    width: 100%;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    background-color: var(--white);
    transition: all 0.3s ease;
}

.custom-dropdown[open] {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 213, 0, 0.15);
}

.custom-dropdown summary {
    padding: 1rem 1.25rem;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    color: var(--text-main);
    cursor: pointer;
    list-style: none;
    position: relative;
    outline: none;
}

.custom-dropdown summary::-webkit-details-marker {
    display: none;
}

.custom-dropdown summary::after {
    content: "";
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    transition: transform 0.3s ease;
}

.custom-dropdown[open] summary::after {
    transform: translateY(-50%) rotate(180deg);
}

.custom-dropdown .dropdown-content {
    padding: 0.5rem 1.25rem 1.25rem;
    border-top: 1px solid var(--border);
    max-height: 250px;
    overflow-y: auto;
}

/* Custom Radios & Checkboxes */
.radio-group, .checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.radio-group.grid-2, .checkbox-group.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.radio-group.vertical, .checkbox-group.vertical {
    flex-direction: column;
}

.radio-label, .checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-weight: 500;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    background-color: var(--white);
    transition: all 0.2s ease;
    margin-bottom: 0;
}

.dropdown-content .checkbox-label {
    margin-bottom: 0.5rem;
}

.radio-label:hover, .checkbox-label:hover {
    border-color: var(--primary-light);
    background-color: #FAFAFA;
}

.radio-label input, .checkbox-label input {
    margin-right: 0.75rem;
    width: 1.2rem;
    height: 1.2rem;
    accent-color: var(--primary);
    cursor: pointer;
}

/* Selected state for custom radio/checkbox wrapper */
.radio-label:has(input:checked), .checkbox-label:has(input:checked) {
    border-color: var(--primary);
    background-color: rgba(255, 213, 0, 0.08);
}

/* Form Actions */
.form-actions {
    margin-top: 1rem;
    text-align: center;
    animation: fadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: 0.5s;
}

.btn-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background-color: var(--primary);
    color: var(--dark);
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 1.2rem;
    padding: 1.2rem 3rem;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 213, 0, 0.4);
    background-color: #FFDF33;
}

.btn-submit:active {
    transform: translateY(1px);
}

/* Form Message */
.form-message {
    margin-top: 1.5rem;
    padding: 1rem;
    border-radius: var(--radius-md);
    text-align: center;
    font-weight: 600;
    display: none;
}

.form-message.success {
    display: block;
    background-color: #DEF7EC;
    color: #03543F;
    border: 1px solid #31C48D;
}

.form-message.error {
    display: block;
    background-color: #FDE8E8;
    color: #9B1C1C;
    border: 1px solid #F98080;
}

/* Animations */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

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



/* Responsive */
@media (max-width: 768px) {
    .form-row, .radio-group.grid-2, .checkbox-group.grid-2 {
        grid-template-columns: 1fr;
    }
    
    .form-section {
        padding: 1.5rem;
    }
    
    .header h1 {
        font-size: 1.8rem;
    }
}
