:root {
    --primary: #6B5B95;
    --secondary: #fff;
    --accent: #F8B195;
    --background: #F6F5FF;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: var(--background);
}

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

.header {
    background: linear-gradient(135deg, var(--primary), #8675A9);
    color: var(--secondary);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(107, 91, 149, 0.2);
    position: relative;
}

.input-section {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.grid-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.form-group {
    margin-bottom: 15px;
}

input, select {
    width: 100%;
    padding: 12px;
    border: 1px solid #E8E8E8;
    border-radius: 8px;
    background-color: #FAFAFA;
    transition: all 0.3s ease;
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(107, 91, 149, 0.2);
}

button {
    background: linear-gradient(135deg, var(--primary), #8675A9);
    color: var(--secondary);
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    width: 100%;
    font-weight: 600;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(107, 91, 149, 0.3);
}

.charts-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.chart-wrapper {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.insights-section {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    margin-top: 20px;
}

.insight-card {
    border-left: 4px solid var(--primary);
    padding: 15px;
    margin-bottom: 15px;
    background-color: #F8F7FF;
    border-radius: 0 8px 8px 0;
    transition: transform 0.2s;
}

.insight-card:hover {
    transform: translateX(5px);
}

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

.animate-in {
    animation: fadeIn 0.5s ease-out forwards;
}

.summary-card {
    background: linear-gradient(135deg, #F8F7FF, #F0EEFF);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.login-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--background);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.login-container {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(107, 91, 149, 0.2);
    width: 100%;
    max-width: 400px;
    animation: fadeIn 0.5s ease-out forwards;
}

.login-header {
    text-align: center;
    color: var(--primary);
    margin-bottom: 25px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-form input {
    margin-bottom: 10px;
}

.login-error {
    color: #ff4444;
    text-align: center;
    margin-top: 10px;
    font-size: 0.9em;
}

.signup-container {
    display: none; /* Hidden by default */
}

.toggle-form {
    color: var(--primary);
    text-decoration: underline;
    cursor: pointer;
    text-align: center;
    margin-top: 15px;
}

.form-title {
    margin-bottom: 20px;
    text-align: center;
}

.logout-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: auto;
    padding: 8px 16px;
    background: rgba(255,255,255,0.2);
    border: 1px solid white;
}

/* Footer Styles */
.footer {
    text-align: center;
    padding: 20px;
    margin-top: 40px;
    color: var(--primary);
    border-top: 1px solid #E8E8E8;
}

.footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    margin: 0 10px;
    transition: color 0.2s;
}

.footer a:hover {
    color: var(--accent);
}

.footer p {
    margin: 10px 0;
    font-size: 0.9em;
}

/* Privacy Modal Styles */
.privacy-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none; /* Hidden by default */
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.privacy-container {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    animation: fadeIn 0.3s ease-out forwards;
    position: relative;
}

.privacy-container h2 {
    color: var(--primary);
    margin-top: 0;
    border-bottom: 2px solid var(--background);
    padding-bottom: 10px;
}

.privacy-container p, .privacy-container li {
    line-height: 1.6;
    color: #444;
}

.close-privacy-btn {
    margin-top: 20px;
    width: auto;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.login-footer {
    position: absolute;
    bottom: 10px;
    width: 100%;
    border-top: none;
    margin-top: 0;
}
