/* Import animations */
@import url('animations.css');
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* Base styles */
body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    background: #23242a;
    color: #e0ffe0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: all 0.3s ease;
}

/* Header styles */
header {
    background: linear-gradient(to right, #1c1c1c, #45f3ff);
    color: #fff;
    padding: 1.2rem 2.5rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 10;
}

header h1 {
    margin: 0;
    font-size: 2rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

/* Navigation buttons */
.nav-button {
    background: linear-gradient(135deg, #1c1c1c, #45f3ff);
    color: #fff;
    border: none;
    padding: 0.7rem 1.4rem;
    margin-left: 12px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.nav-button:hover {
    background: linear-gradient(135deg, #23242a, #45f3ff);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Main content area */
main {
    flex-grow: 1;
    padding: 2.5rem;
    max-width: 800px;
    margin: 30px auto;
    background: linear-gradient(135deg, #1c1c1c, #23242a);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

main:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
    transform: translateY(-5px);
}

/* Section styles */
section {
    margin-bottom: 2.5rem;
    padding: 2rem;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #1c1c1c, #23242a);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

section:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

/* Headings */
h2 {
    color: #00b300;
    text-align: center;
    margin-bottom: 1.8rem;
    font-size: 1.8rem;
    font-weight: 600;
    position: relative;
    padding-bottom: 10px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(to right, #004d00, #00b300);
    border-radius: 3px;
}

/* Auth section styles */
.auth-section input[type="email"],
.auth-section input[type="password"] {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 20px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.auth-section input[type="email"]:focus,
.auth-section input[type="password"]:focus {
    border-color: #66bb6a;
    box-shadow: 0 0 0 3px rgba(102, 187, 106, 0.2);
    outline: none;
}

.auth-section button {
    width: 100%;
    padding: 14px;
    background: linear-gradient(to right, #43a047, #66bb6a);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(102, 187, 106, 0.3);
}

.auth-section button:hover {
    background: linear-gradient(to right, #388e3c, #4caf50);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(102, 187, 106, 0.4);
}

.auth-section p {
    text-align: center;
    margin-top: 20px;
    font-size: 0.95rem;
    color: #666;
}

.auth-section a {
    color: #43a047;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.auth-section a:hover {
    color: #2e7d32;
    text-decoration: none;
}

/* Message styles */
.error-message {
    color: #d32f2f;
    background-color: #ffebee;
    border: 1px solid #ffcdd2;
    padding: 12px;
    border-radius: 8px;
    margin-top: 15px;
    text-align: center;
    display: none; /* Hidden by default */
    box-shadow: 0 2px 8px rgba(211, 47, 47, 0.1);
}

.info-message {
    color: #0288d1;
    background-color: #e1f5fe;
    border: 1px solid #b3e5fc;
    padding: 12px;
    border-radius: 8px;
    margin-top: 15px;
    text-align: center;
    display: none; /* Hidden by default */
    box-shadow: 0 2px 8px rgba(2, 136, 209, 0.1);
}

/* Success message style */
.success-message {
    color: #388e3c;
    background-color: #e8f5e8;
    border: 1px solid #c8e6c9;
    padding: 12px;
    border-radius: 8px;
    margin-top: 15px;
    text-align: center;
    display: none; /* Hidden by default */
    box-shadow: 0 2px 8px rgba(56, 142, 60, 0.1);
}

/* Dashboard styles */
#dashboard-user-info {
    text-align: center;
    margin-bottom: 1.8rem;
    font-style: italic;
    color: #555;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

#dashboard-prayer-meta {
    text-align: center;
    margin-bottom: 1.2rem;
    color: #555;
    font-size: 1.1rem;
}

#dashboard-prayer-list-simple {
    text-align: center;
    margin-bottom: 1.5rem;
    color: #666;
    font-size: 0.95rem;
}

#dashboard-prayer-list-simple p {
    margin: 5px 0;
}

/* Prayer list styles */
.prayer-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.prayer-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #1c1c1c, #23242a);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    gap: 15px;
    transition: all 0.3s ease;
}

.prayer-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.12);
}

.prayer-item span {
    font-size: 1.15rem;
    font-weight: 500;
    color: #444;
}

.prayer-item span.prayer-time {
    font-family: 'Poppins', sans-serif;
    font-size: 1.15rem;
    color: #0288d1;
    min-width: 70px;
    text-align: center;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Prayer toggle buttons */
.toggle-prayer-btn {
    border: none;
    padding: 10px 18px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 1.2rem;
    min-width: 50px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-weight: bold;
    user-select: none;
}

/* Default state - missed (red with X) */
.toggle-prayer-btn.missed {
    background: linear-gradient(135deg, #660000, #990000);
    color: white;
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.3);
}

.toggle-prayer-btn.missed:hover {
    background: linear-gradient(135deg, #800000, #cc0000);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(244, 67, 54, 0.4);
}

/* Done state - completed (green with checkmark) */
.toggle-prayer-btn.done {
    background: linear-gradient(135deg, #004d00, #45f3ff);
    color: white;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.toggle-prayer-btn.done:hover {
    background: linear-gradient(135deg, #006600, #00b300);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(76, 175, 80, 0.4);
}

/* Active states */
.toggle-prayer-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* History controls */
.history-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

#history-days {
    padding: 10px 15px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    font-size: 1rem;
    background-color: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

#history-days:focus {
    border-color:#ff6b8a;
    box-shadow: 0 0 0 3px rgba(102, 187, 106, 0.2);
    outline: none;
}

#load-history-btn {
    padding: 10px 20px;
    background: linear-gradient(to right, #2196f3, #4dabf5);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(33, 150, 243, 0.3);
}

#load-history-btn:hover {
    background: linear-gradient(to right, #1976d2, #2196f3);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(33, 150, 243, 0.4);
}

/* History day card */
.history-day-card {
    background-color: #000000;
    border: none;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.history-day-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.history-day-card h3 {
    color: #4dabf5;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.4rem;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
    font-weight: 600;
}

.history-day-card .prayer-item {
    padding: 10px 15px;
    margin-bottom: 8px;
    font-size: 1rem;
    background-color: #f9f9f9;
}

.history-day-card .prayer-item button {
    font-size: 1rem;
    padding: 8px 12px;
    min-width: 40px;
}

/* Footer */
footer {
    background: linear-gradient(to right, #1c1c1c, #45f3ff);
    color: #fff;
    text-align: center;
    padding: 1.2rem 0;
    margin-top: auto;
    font-size: 0.9rem;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.1);
}

/* Utility classes */
.hidden {
    display: none !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    header {
        padding: 1rem 1.5rem;
        flex-direction: column;
        gap: 10px;
    }
    
    main {
        padding: 1.5rem;
        margin: 20px 10px;
    }
    
    section {
        padding: 1.5rem;
    }
    
    .nav-button {
        margin: 5px;
    }
    
    .history-controls {
        flex-direction: column;
    }
}