/* assets/css/style.css */
:root {
    --primary-color: #ff6b9d;
    --secondary-color: #9b59b6;
    --accent-color: #f1c40f;
    --background-light: #fff9fb;
    --text-dark: #2c3e50;
    --text-light: #ffffff;
    --success-color: #2ecc71;
    --gradient-primary: linear-gradient(135deg, #ff6b9d, #9b59b6);
    --gradient-gold: linear-gradient(135deg, #f1c40f, #e67e22);
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-md: 0 5px 20px rgba(0,0,0,0.15);
    --shadow-lg: 0 10px 30px rgba(0,0,0,0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--background-light);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
}

/* Lotus Animation Background */
.lotus-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    opacity: 0.03;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M50 20 Q60 10 70 20 Q80 30 70 40 Q60 50 50 40 Q40 50 30 40 Q20 30 30 20 Q40 10 50 20" fill="%239b59b6"/></svg>') repeat;
    animation: floatLotus 20s linear infinite;
}

@keyframes floatLotus {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(5deg) scale(1.05); }
    100% { transform: rotate(0deg) scale(1); }
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
    position: relative;
    z-index: 1;
}

/* Header Styles */
.header {
    background: var(--gradient-primary);
    color: var(--text-light);
    padding: 1.5rem 1rem;
    border-radius: 0 0 30px 30px;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.header::before {
    content: "🌸";
    position: absolute;
    right: -20px;
    top: -20px;
    font-size: 150px;
    opacity: 0.1;
    transform: rotate(15deg);
}

.header h1 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.header p {
    font-size: 1rem;
    opacity: 0.9;
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.stat-card {
    background: white;
    border-radius: 20px;
    padding: 1.5rem 1rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stat-card:hover::after {
    transform: scaleX(1);
}

.stat-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.9rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Progress Circle */
.progress-container {
    background: white;
    border-radius: 30px;
    padding: 2rem 1rem;
    margin: 2rem 0;
    text-align: center;
    box-shadow: var(--shadow-md);
}

.progress-circle {
    width: 200px;
    height: 200px;
    margin: 0 auto 1.5rem;
    position: relative;
}

.progress-circle svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-circle circle {
    fill: none;
    stroke-width: 8;
    stroke-linecap: round;
}

.progress-circle .bg-circle {
    stroke: #f0f0f0;
}

.progress-circle .progress-circle-fill {
    stroke: url(#gradient);
    stroke-dasharray: 565.48;
    stroke-dashoffset: 565.48;
    transition: stroke-dashoffset 0.5s ease;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.progress-label {
    font-size: 1.1rem;
    color: #666;
}

/* Add Japa Form */
.add-japa-form {
    background: white;
    border-radius: 30px;
    padding: 2rem 1.5rem;
    margin: 2rem 0;
    box-shadow: var(--shadow-md);
}

.form-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-title i {
    font-size: 1.8rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-dark);
}

.form-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    font-size: 1.1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
}

.unit-hint {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 1rem;
    margin: 1rem 0;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.95rem;
    color: #666;
}

.unit-hint i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.btn {
    background: var(--gradient-primary);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    width: 100%;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn:active {
    transform: translateY(0);
}

/* Milestones Grid */
.milestones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.milestone-card {
    background: white;
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
}

.milestone-card.achieved {
    background: linear-gradient(135deg, #fff9fb, #fff);
    border-color: var(--success-color);
}

.milestone-card.achieved::before {
    content: "✓";
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    background: var(--success-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
}

.milestone-card.next {
    border-color: var(--accent-color);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(241, 196, 15, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(241, 196, 15, 0); }
    100% { box-shadow: 0 0 0 0 rgba(241, 196, 15, 0); }
}

.milestone-count {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.milestone-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.milestone-desc {
    color: #666;
    font-size: 0.95rem;
}

.milestone-progress {
    margin-top: 1rem;
    height: 6px;
    background: #f0f0f0;
    border-radius: 3px;
    overflow: hidden;
}

.milestone-progress-bar {
    height: 100%;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

/* Quote Section */
.quote-section {
    background: var(--gradient-gold);
    color: white;
    border-radius: 30px;
    padding: 2rem;
    margin: 2rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.quote-section::before {
    content: """;
    position: absolute;
    top: -20px;
    left: 10px;
    font-size: 150px;
    opacity: 0.1;
    font-family: serif;
}

.quote-text {
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 1rem;
    line-height: 1.8;
}

.quote-author {
    font-size: 1rem;
    opacity: 0.9;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    display: flex;
    justify-content: space-around;
    padding: 0.75rem 1rem;
    box-shadow: 0 -2px 20px rgba(0,0,0,0.1);
    border-radius: 30px 30px 0 0;
    z-index: 100;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #666;
    font-size: 0.75rem;
    transition: color 0.3s ease;
}

.nav-item i {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
}

.nav-item.active {
    color: var(--primary-color);
}

.nav-item:hover {
    color: var(--primary-color);
}

/* Responsive Design */
@media (min-width: 768px) {
    .container {
        padding: 2rem;
    }
    
    .header h1 {
        font-size: 2.5rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .bottom-nav {
        max-width: 400px;
        left: 50%;
        transform: translateX(-50%);
        border-radius: 50px;
        bottom: 1rem;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.5s ease forwards;
}

@keyframes lotusBloom {
    0% { transform: scale(0.8) rotate(0deg); opacity: 0; }
    50% { transform: scale(1.1) rotate(5deg); opacity: 0.5; }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.lotus-icon {
    animation: lotusBloom 1s ease;
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Toast Notifications */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    border-radius: 10px;
    padding: 1rem;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 1rem;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 1000;
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    border-left: 4px solid var(--success-color);
}

.toast i {
    font-size: 1.5rem;
    color: var(--success-color);
}