/* ==========================================================================
   Design Tokens & CSS Variables
   ========================================================================== */
:root {
    --bg-primary: #0a0d14;
    --bg-card: rgba(18, 24, 38, 0.72);
    --bg-card-border: rgba(255, 255, 255, 0.08);
    --bg-input: rgba(13, 17, 28, 0.7);
    --bg-input-focus: rgba(17, 24, 39, 0.95);

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --text-placeholder: #475569;

    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #d946ef 100%);
    --accent-gradient-hover: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #c026d3 100%);
    --accent-glow: rgba(99, 102, 241, 0.35);
    
    --primary-color: #6366f1;
    --success-bg: rgba(16, 185, 129, 0.12);
    --success-border: rgba(16, 185, 129, 0.3);
    --success-text: #34d399;
    --error-bg: rgba(239, 68, 68, 0.12);
    --error-border: rgba(239, 68, 68, 0.3);
    --error-text: #f87171;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-card: 0 20px 50px -10px rgba(0, 0, 0, 0.5), 0 0 1px 1px rgba(255, 255, 255, 0.05);
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Plus Jakarta Sans', 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ==========================================================================
   Ambient Background Glows
   ========================================================================== */
.glow-bg {
    position: fixed;
    border-radius: 50%;
    filter: blur(130px);
    opacity: 0.45;
    pointer-events: none;
    z-index: 0;
    animation: floatGlow 12s ease-in-out infinite alternate;
}

.glow-1 {
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, #6366f1 0%, transparent 70%);
    top: -120px;
    left: -100px;
}

.glow-2 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, #a855f7 0%, transparent 70%);
    top: 40%;
    right: -150px;
    animation-delay: -4s;
}

.glow-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #06b6d4 0%, transparent 70%);
    bottom: -100px;
    left: 20%;
    animation-delay: -8s;
}

@keyframes floatGlow {
    0% {
        transform: translate(0, 0) scale(1);
    }
    100% {
        transform: translate(30px, 40px) scale(1.08);
    }
}

/* ==========================================================================
   Layout & Container
   ========================================================================== */
.container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 680px;
    margin: 48px auto;
    padding: 0 20px;
}

.form-wrapper {
    background: var(--bg-card);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--bg-card-border);
    border-radius: var(--radius-lg);
    padding: 44px 40px;
    box-shadow: var(--shadow-card);
    transition: transform var(--transition-smooth), border-color var(--transition-smooth);
}

.form-wrapper:hover {
    border-color: rgba(255, 255, 255, 0.14);
}

/* ==========================================================================
   Header & Typography
   ========================================================================== */
.form-header {
    text-align: center;
    margin-bottom: 36px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #a5b4fc;
    margin-bottom: 18px;
    text-transform: uppercase;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background-color: #6366f1;
    box-shadow: 0 0 10px #6366f1;
    animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.85); }
}

.title {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.02em;
    background: linear-gradient(180deg, #ffffff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 12px;
}

.subtitle {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    font-weight: 400;
}

/* ==========================================================================
   Form Components
   ========================================================================== */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .form-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .form-wrapper {
        padding: 30px 20px;
    }
    .title {
        font-size: 1.6rem;
    }
}

.form-group {
    margin-bottom: 22px;
    display: flex;
    flex-direction: column;
}

.form-label {
    font-size: 0.88rem;
    font-weight: 600;
    color: #e2e8f0;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.required {
    color: #f43f5e;
    font-weight: bold;
}

.optional {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 400;
}

.input-wrapper {
    position: relative;
    width: 100%;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    background-color: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: 13px 16px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all var(--transition-fast);
    outline: none;
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-placeholder);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    background-color: var(--bg-input-focus);
    border-color: #818cf8;
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' 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 14px center;
    padding-right: 40px;
    cursor: pointer;
}

.form-select option {
    background-color: #111827;
    color: #f8fafc;
    padding: 10px;
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
    line-height: 1.6;
}

/* ==========================================================================
   Checkbox Agreement
   ========================================================================== */
.agreement-group {
    margin-top: 6px;
    margin-bottom: 28px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
    font-size: 0.88rem;
    color: var(--text-secondary);
    gap: 10px;
}

.checkbox-container input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.custom-checkbox {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border-radius: var(--radius-sm);
    background: var(--bg-input);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.checkbox-container input:checked ~ .custom-checkbox {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-color: #818cf8;
}

.checkbox-container input:checked ~ .custom-checkbox::after {
    content: '';
    display: block;
    width: 5px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) translate(-1px, -1px);
}

.checkbox-container:hover .custom-checkbox {
    border-color: #818cf8;
}

/* ==========================================================================
   Submit Button
   ========================================================================== */
.submit-button {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 24px;
    background: var(--accent-gradient);
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    font-family: inherit;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-smooth);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
    position: relative;
    overflow: hidden;
}

.submit-button:hover:not(:disabled) {
    background: var(--accent-gradient-hover);
    box-shadow: 0 12px 30px rgba(99, 102, 241, 0.5);
    transform: translateY(-2px);
}

.submit-button:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.submit-button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.btn-icon {
    transition: transform var(--transition-fast);
}

.submit-button:hover:not(:disabled) .btn-icon {
    transform: translateX(4px);
}

.btn-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Status Box (Success / Error Notification)
   ========================================================================== */
.status-box {
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 24px;
    font-size: 0.92rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease-in-out;
}

.status-box.success {
    background-color: var(--success-bg);
    border: 1px solid var(--success-border);
    color: var(--success-text);
}

.status-box.error {
    background-color: var(--error-bg);
    border: 1px solid var(--error-border);
    color: var(--error-text);
}

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

/* ==========================================================================
   Comments Section (Disqus)
   ========================================================================== */
.comments-wrapper {
    background: var(--bg-card);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--bg-card-border);
    border-radius: var(--radius-lg);
    padding: 36px 40px;
    margin-top: 32px;
    box-shadow: var(--shadow-card);
    transition: border-color var(--transition-smooth);
}

.comments-wrapper:hover {
    border-color: rgba(255, 255, 255, 0.14);
}

.comments-header {
    margin-bottom: 24px;
}

.comments-badge {
    margin-bottom: 12px;
}

.comments-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.comments-subtitle {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

#disqus_thread {
    min-height: 200px;
    margin-top: 20px;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 24px;
    color: var(--text-muted);
    font-size: 0.82rem;
}

