:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --secondary: #ec4899;
    --bg-dark: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --border: rgba(255, 255, 255, 0.1);
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(236, 72, 153, 0.15) 0px, transparent 50%);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.container {
    width: 100%;
    max-width: 1000px;
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 3rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.8s ease-out;
}

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

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

header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    background: linear-gradient(to right, #818cf8, #f472b6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

select, input {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.2s;
}

select:focus, input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.btn-predict {
    width: 100%;
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 14px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.btn-predict:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4);
}

.btn-predict:active {
    transform: translateY(0);
}

.section-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 2.5rem 0 1rem 0;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
    padding-bottom: 0.5rem;
}

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

.radio-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.95rem;
    color: var(--text-main);
}

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

.result-card {
    margin-top: 3rem;
    padding: 2rem;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 20px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    text-align: center;
    display: none;
}

.result-card.active {
    display: block;
    animation: zoomIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.result-price {
    font-size: 3.5rem;
    font-weight: 800;
    color: #4ade80;
    text-shadow: 0 0 20px rgba(74, 222, 128, 0.3);
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
    display: none;
}

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

.info-banner {
    margin-top: 2rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.6;
}

/* 📱 Mobile Responsiveness */
@media (max-width: 768px) {
    body {
        padding: 1rem;
    }

    .container {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    header h1 {
        font-size: 2rem;
    }

    header p {
        font-size: 1rem;
    }

    .grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .result-price {
        font-size: 2.5rem;
    }

    .section-title {
        margin-top: 2rem;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.75rem;
    }

    .container {
        padding: 1.5rem 1rem;
    }

    .btn-predict {
        padding: 0.85rem;
        font-size: 1rem;
    }

    .radio-group {
        flex-direction: column;
        gap: 0.75rem;
    }
}
