:root {
    --bg-color: #0f172a;
    --primary-color: #f59e0b;
    /* Amber/Gold */
    --secondary-color: #10b981;
    /* Emerald Green */
    --accent-color: #8b5cf6;
    /* Violet */
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --glass-bg: rgba(30, 41, 59, 0.3);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    /* background-color: var(--bg-color); */
    background-image: url('images/background.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
}

/* Background Animations - Hidden for Image Background */
.background-blobs {
    display: none;
    /*
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    */
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    animation: float 10s infinite ease-in-out;
}

.blob-1 {
    width: 400px;
    height: 400px;
    background: var(--primary-color);
    top: -100px;
    left: -100px;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: var(--accent-color);
    bottom: -150px;
    right: -150px;
    animation-delay: 2s;
}

.blob-3 {
    width: 300px;
    height: 300px;
    background: var(--secondary-color);
    top: 40%;
    left: 40%;
    animation-delay: 4s;
    opacity: 0.4;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(30px, 50px);
    }
}

/* Layout */
.container {
    width: 100%;
    max-width: 1000px;
    padding: 20px;
    text-align: center;
    z-index: 10;
}

/* Navigation Styles */
.glass-nav {
    display: inline-block;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 5px;
    margin-bottom: 30px;
}

.glass-nav ul {
    list-style: none;
    display: flex;
    gap: 5px;
}

.glass-nav li {
    display: inline-block;
}

.nav-item {
    text-decoration: none;
    color: var(--text-secondary);
    padding: 10px 24px;
    border-radius: 40px;
    display: inline-block;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-item:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.nav-item.active {
    background: var(--primary-color);
    color: #1e293b;
    /* Dark text for contrast on gold/amber */
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

header {
    margin-bottom: 40px;
}

header h1 {
    font-size: 3.5rem;
    /* Increased from 3rem */
    font-weight: 700;
    background: linear-gradient(to right, #fff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 15px;
    /* Increased margin */
}

header p {
    color: var(--text-secondary);
    font-size: 1.3rem;
    /* Increased from 1.1rem */
}

/* Glass Panel */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    /* Increased radius */
    padding: 60px;
    /* Increased from 40px */
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    /* Increased from 40px */
    align-items: center;
}

/* About Panel Style Override */
.about-panel {
    display: block;
    /* Remove grid for text content */
    text-align: left;
    max-width: 1000px;
    /* Increased from 800px */
    margin: 0 auto;
}

.about-content h2 {
    color: var(--primary-color);
    margin-bottom: 25px;
    font-size: 2.5rem;
    /* Increased from 2rem */
}

.about-content p {
    font-size: 1.2rem;
    /* Increased font size */
    margin-bottom: 20px;
    line-height: 1.8;
    /* Increased line-height */
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .glass-panel {
        grid-template-columns: 1fr;
    }
}

/* Upload Section */
.drop-zone {
    border: 2px dashed var(--glass-border);
    border-radius: 16px;
    padding: 40px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.02);
}

.drop-zone:hover,
.drop-zone.dragover {
    border-color: var(--primary-color);
    background: rgba(245, 158, 11, 0.1);
    transform: scale(1.02);
}

.icon-container {
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.drop-zone h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.drop-zone p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.preview-container {
    margin-top: 20px;
    position: relative;
    width: 100%;
    /* Ensure full width in container */
    display: flex;
    justify-content: center;
}

.preview-container img {
    width: 100%;
    max-width: 300px;
    /* Limit max width */
    max-height: 300px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

.remove-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    transform: translateX(50%);
    /* Adjust if outside */
    right: calc(50% - 140px);
    /* Rough centering adjustment if needed, or put inside wrapper */
    /* Better positioning: */
    right: auto;
    margin-left: 260px;
    /* Offset from center */

    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    padding: 5px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background 0.3s;
}

/* Simplify remove button positioning for the demo */
.preview-container {
    position: relative;
    display: inline-block;
    /* Wrap image tightly */
}

.remove-btn {
    right: 5px;
    top: 5px;
    margin: 0;
    transform: none;
}


.remove-btn:hover {
    background: rgba(239, 68, 68, 0.8);
}

/* Result Section */
.result-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    border-left: 1px solid var(--glass-border);
    padding-left: 40px;
}

@media (max-width: 768px) {
    .result-section {
        border-left: none;
        border-top: 1px solid var(--glass-border);
        padding-left: 0;
        padding-top: 40px;
    }
}

.placeholder-text {
    color: var(--text-secondary);
    font-style: italic;
}

.prediction-card {
    text-align: center;
    width: 100%;
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.label {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    display: block;
}

.prediction-card h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: white;
}

.confidence-bar-container {
    width: 100%;
    height: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 10px;
}

.confidence-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    width: 0%;
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.confidence-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Loader */
.loader {
    text-align: center;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-left-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

.hidden {
    display: none !important;
}

footer {
    margin-top: 40px;
    color: var(--text-secondary);
    font-size: 0.8rem;
    opacity: 0.7;
}