/* 
  Study Syns - Unified Premium Design System
  Glassmorphism + Dynamic Themes + Micro-animations
*/

:root {
    /* --- Dark Mode Colors --- */
    --bg-main: #0a1929;
    --bg-secondary: #132f4c;
    --card-bg: #1e3a5f;
    --card-bg-hover: #2a4a6f;

    --primary-color: #3b82f6;
    --primary-light: #60a5fa;
    --primary-dark: #2563eb;
    --secondary-color: #60a5fa;
    --accent-glow: rgba(59, 130, 246, 0.4);

    --text-main: #e3f2fd;
    --text-secondary: #bbdefb;
    --text-muted: #7da8c9;

    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #06b6d4;

    --card-border: rgba(59, 130, 246, 0.15);
    --nav-bg: rgba(10, 25, 41, 0.8);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 20px rgba(59, 130, 246, 0.3);
}

[data-theme="light"] {
    /* --- Light Mode Colors --- */
    --bg-main: #f8fafc;
    --bg-secondary: #f1f5f9;
    --card-bg: rgba(255, 255, 255, 0.9);
    --card-bg-hover: #ffffff;

    --primary-color: #2563eb;
    --primary-light: #3b82f6;
    --primary-dark: #1d4ed8;
    --secondary-color: #3b82f6;
    --accent-glow: rgba(37, 99, 235, 0.15);

    --text-main: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;

    --success-color: #059669;
    --warning-color: #d97706;
    --danger-color: #dc2626;
    --info-color: #0891b2;

    --card-border: rgba(37, 99, 235, 0.1);
    --nav-bg: rgba(255, 255, 255, 0.85);
    --shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
    --shadow-glow: 0 0 15px rgba(37, 99, 235, 0.1);
}

/* Base Reset */
* {
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Cairo', sans-serif;
    margin: 0;
    min-height: 100vh;
    padding-bottom: 80px;
    /* Space for nav */
    overflow-x: hidden;
}

/* Premium Decorations */
.bg-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

@keyframes blob-float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -50px) scale(1.1);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }

    100% {
        transform: translate(0, 0) scale(1);
    }
}

@keyframes mesh-rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.15;
    animation: blob-float 20s infinite alternate cubic-bezier(0.445, 0.05, 0.55, 0.95);
    z-index: -1;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: var(--primary-color);
    top: -200px;
    right: -100px;
    opacity: 0.2;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: var(--secondary-color);
    bottom: -100px;
    left: -100px;
    animation-delay: -5s;
    opacity: 0.15;
}

.blob-3 {
    width: 400px;
    height: 400px;
    background: #10b981;
    /* Success accent */
    top: 40%;
    left: 20%;
    animation-delay: -10s;
    opacity: 0.1;
}

.bg-texture {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03;
    pointer-events: none;
    z-index: -1;
}

[data-theme="light"] .blob {
    opacity: 0.1;
    filter: blur(150px);
}

@keyframes geo-float {
    0% {
        transform: translate(0, 0) rotate(0deg);
        opacity: 0.2;
    }

    33% {
        transform: translate(30px, -50px) rotate(120deg);
        opacity: 0.4;
    }

    66% {
        transform: translate(-20px, 20px) rotate(240deg);
        opacity: 0.3;
    }

    100% {
        transform: translate(0, 0) rotate(360deg);
        opacity: 0.2;
    }
}

@keyframes geo-float-slow {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }

    50% {
        transform: translate(-40px, 40px) rotate(-180deg);
    }

    100% {
        transform: translate(0, 0) rotate(-360deg);
    }
}

.bg-geometry {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.geo-shape {
    position: absolute;
    border: 1.5px solid var(--primary-color);
    opacity: 0.1;
    filter: blur(0px);
    animation: geo-float 25s infinite linear;
    pointer-events: none;
    z-index: -1;
    box-shadow: 0 0 15px var(--accent-glow);
    background: rgba(255, 255, 255, 0.02);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

.geo-shape.circle {
    border-radius: 50%;
}

.geo-shape.square {
    border-radius: 12px;
}

.geo-shape.triangle {
    width: 0 !important;
    height: 0 !important;
    border: none !important;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-bottom: 35px solid var(--primary-color);
    background: transparent !important;
    opacity: 0.05;
    filter: drop-shadow(0 0 10px var(--accent-glow));
}

.geo-shape.ring {
    border-width: 6px;
    background: transparent;
    box-shadow: inset 0 0 10px var(--accent-glow), 0 0 10px var(--accent-glow);
}

.geo-shape.dot {
    background: var(--primary-color);
    border: none;
    opacity: 0.2;
    box-shadow: 0 0 15px var(--primary-color);
}

.geo-shape.dashed {
    border-style: dashed;
    border-width: 2px;
}

/* Speed Variations */
.geo-speed-slow {
    animation-duration: 45s;
}

.geo-speed-medium {
    animation-duration: 30s;
}

.geo-speed-fast {
    animation-duration: 18s;
}


.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(var(--primary-color) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.04;
    z-index: -1;
    pointer-events: none;
}

[data-theme="light"] .bg-grid {
    opacity: 0.025;
}

[data-theme="light"] .geo-shape {
    opacity: 0.06;
}

/* Global Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    animation: fadeInUp 0.8s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

/* Floating Animations for icons/cards */
@keyframes float-y {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes float-rotate {

    0%,
    100% {
        transform: rotate(-2deg);
    }

    50% {
        transform: rotate(2deg);
    }
}

@keyframes pulse-glow {

    0%,
    100% {
        box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
    }

    50% {
        box-shadow: 0 0 30px rgba(59, 130, 246, 0.6), 0 0 15px rgba(59, 130, 246, 0.4);
    }
}

@keyframes live-pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.floating-icon,
.stat-icon,
.card-icon,
.perf-icon {
    display: inline-block;
    animation: float-y 3s ease-in-out infinite;
}

.premium-card:hover .stat-icon {
    animation: float-rotate 1s ease-in-out infinite;
}

/* Enhanced Shine and Glow */
.premium-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.15),
            transparent);
    transform: skewX(-30deg);
    animation: shine-glow 6s infinite linear;
    pointer-events: none;
}

@keyframes shine-glow {
    0% {
        left: -150%;
    }

    20%,
    100% {
        left: 150%;
    }
}

/* Force High Contrast Text & Visibility Safety */
h1,
h2,
h3,
h4,
h5,
h6,
.card-title,
.page-title,
.hero-title,
.logo-text,
.section-title {
    color: var(--text-main) !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

p,
span,
.card-description,
.stat-label,
.perf-label,
.setting-label span,
.form-label,
.type-name,
.nav-label,
.duration-value,
.slider-min,
.slider-max,
.status-text,
.char-counter,
.no-tasks-message p,
.task-meta,
.task-time-info {
    color: var(--text-secondary) !important;
}

.stat-value,
.perf-value,
.stat-value-large,
.task-title,
.logo-icon {
    color: var(--text-main) !important;
    font-weight: 800;
}

/* Hero Subtitle Attention-Grabbing Style */
.hero-subtitle.animate-on-load {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUpHero 1s cubic-bezier(0.23, 1, 0.32, 1) 0.5s forwards;
    background: rgba(255, 255, 255, 0.03);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    padding: 15px 25px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    display: inline-block;
    max-width: 800px;
    margin: 20px auto;
    font-weight: 500;
    line-height: 1.8;
}

@keyframes fadeInUpHero {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

[data-theme="light"] .hero-subtitle.animate-on-load {
    background: rgba(59, 130, 246, 0.05);
    border-color: rgba(59, 130, 246, 0.1);
    color: #1e293b !important;
}

[data-theme="dark"] .hero-subtitle.animate-on-load {
    color: #e2e8f0 !important;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Task Completion Premium Styles */
.task-card.completed {
    opacity: 0.7;
    background: rgba(16, 185, 129, 0.05) !important;
    border-right-color: #10b981 !important;
    transform: scale(0.98);
}

.task-card.completed .task-title {
    text-decoration: line-through;
    color: var(--text-muted) !important;
    opacity: 0.6;
}

/* Success Stamp Overlay */
.task-card.completed::before {
    content: "مكتملة ✓";
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 800;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(16, 185, 129, 0.3);
    z-index: 5;
    animation: stampPulse 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes stampPulse {
    0% {
        transform: scale(0.5) rotate(-15deg);
        opacity: 0;
    }

    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

/* Enhanced Checkbox Animation */
.checkbox-custom::after {
    content: '✓';
    font-size: 16px;
    font-weight: 900;
}

.task-checkbox input:checked+.checkbox-custom {
    animation: checkSuccess 0.4s ease-in-out;
}

@keyframes checkSuccess {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.4);
    }

    100% {
        transform: scale(1);
    }
}

/* Developer Card & Social Links - Unified Premium Design */
.connect-developer-section {
    margin-top: 60px;
    padding-bottom: 20px;
}

.developer-card {
    max-width: 900px;
    margin: 40px auto;
    position: relative;
    padding: 50px 60px;
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.5), rgba(15, 23, 42, 0.7));
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    backdrop-filter: blur(25px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 45px;
    box-shadow:
        0 50px 100px -20px rgba(0, 0, 0, 0.6),
        inset 0 0 40px rgba(59, 130, 246, 0.1);
    display: flex;
    flex-direction: row-reverse;
    /* Avatar on the right */
    align-items: center;
    justify-content: space-between;
    gap: 50px;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

@media (max-width: 768px) {
    .developer-card {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
        gap: 25px;
    }
}

.dev-avatar-section {
    flex-shrink: 0;
}

.dev-text-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
    /* Maintain RTL text alignment */
}

@media (max-width: 768px) {
    .dev-text-section {
        align-items: center;
    }
}


.developer-card:hover {
    transform: translateY(-15px) scale(1.01);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow:
        0 40px 80px -15px rgba(0, 0, 0, 0.7),
        0 0 40px rgba(59, 130, 246, 0.2);
}

[data-theme="light"] .developer-card {
    background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
    border: 1px solid rgba(37, 99, 235, 0.1);
    box-shadow:
        0 40px 80px -15px rgba(15, 23, 42, 0.1),
        inset 0 0 40px rgba(37, 99, 235, 0.05);
}

[data-theme="light"] .dev-name {
    background: linear-gradient(to bottom, #0f172a, #334155);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="light"] .dev-avatar {
    border: 6px solid #ffffff;
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .social-btn {
    background: #ffffff;
    border: 1px solid rgba(37, 99, 235, 0.1);
}

[data-theme="light"] .social-btn:not(:hover) .social-icon-svg {
    fill: #64748b;
}

.dev-info-overlay {
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(59, 130, 246, 0.1), transparent 70%);
    pointer-events: none;
}

.dev-content {
    position: relative;
    z-index: 2;
}

.dev-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    margin-bottom: 35px;
}

.dev-avatar {
    width: 250px;
    height: 250px;
    background: linear-gradient(45deg, var(--primary-color), var(--primary-light));
    padding: 4px;
    border-radius: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    overflow: visible;
}

.dev-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 36px;
    border: 4px solid #0f172a;
}

.online-status-pulse {
    position: absolute;
    bottom: -5px;
    left: -5px;
    width: 15px;
    height: 15px;
    background: #10b981;
    border: 3px solid #0a1929;
    border-radius: 50%;
}

.online-status-pulse::after {
    content: "";
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: #10b981;
    opacity: 0.5;
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {
    0% {
        transform: scale(1);
        opacity: 0.5;
    }

    100% {
        transform: scale(2.5);
        opacity: 0;
    }
}

.dev-name {
    margin: 0;
    font-size: 1.8rem;
    font-weight: 900;
    letter-spacing: -1px;
    background: linear-gradient(to bottom, #ffffff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: none;
}

.dev-role {
    margin: 10px 0 0;
    font-size: 1.1rem;
    color: var(--primary-light) !important;
    font-weight: 600;
    opacity: 0.9;
    letter-spacing: 0.5px;
}

.dev-text-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
}

.dev-bio {
    margin-bottom: 25px;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-secondary) !important;
}

.premium-social {
    display: flex;
    justify-content: flex-start;
    gap: 15px;
    flex-wrap: wrap;
    width: 100%;
    margin-top: 10px;
}


@media (max-width: 768px) {
    .premium-social {
        justify-content: center;
    }
}


.social-btn {
    width: 70px;
    height: 70px;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
}

.social-btn-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0%;
    height: 0%;
    background: var(--primary-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    filter: blur(20px);
    opacity: 0;
    transition: all 0.6s ease;
    z-index: 1;
}

.social-btn:hover {
    transform: translateY(-8px) scale(1.1);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.social-btn:hover .social-btn-glow {
    width: 100%;
    height: 100%;
    opacity: 0.3;
}

.social-icon-svg {
    width: 32px;
    height: 32px;
    fill: #94a3b8;
    position: relative;
    z-index: 2;
    transition: all 0.4s ease;
}

.social-btn:hover .social-icon-svg {
    fill: #ffffff;
    transform: scale(1.1);
}

/* Brand Specific Colors */
.social-btn.whatsapp:hover {
    border-color: #25D366;
}

.social-btn.whatsapp .social-btn-glow {
    background: #25D366;
}

.social-btn.whatsapp:hover .social-icon-svg {
    filter: drop-shadow(0 0 8px #25D366);
}

.social-btn.telegram:hover {
    border-color: #0088cc;
}

.social-btn.telegram .social-btn-glow {
    background: #0088cc;
}

.social-btn.telegram:hover .social-icon-svg {
    filter: drop-shadow(0 0 8px #0088cc);
}

.social-btn.linkedin:hover {
    border-color: #154383;
}

.social-btn.linkedin .social-btn-glow {
    background: #153786d1;
}

.social-btn.linkedin:hover .social-icon-svg {
    filter: drop-shadow(0 0 8px #153786d1);
}

.social-btn.github:hover {
    border-color: #ffffff;
}

.social-btn.github .social-btn-glow {
    background: #000000;
}

.social-btn.github:hover .social-icon-svg {
    filter: drop-shadow(0 0 8px #ffffff);
}

label,
.label-icon {
    color: var(--text-main) !important;
}

[data-theme="light"] {
    --text-main: #020617 !important;
    --text-secondary: #0f172a !important;
    --card-border: rgba(37, 99, 235, 0.3);
}

[data-theme="dark"] {
    --text-main: #ffffff !important;
    --text-secondary: #e2e8f0 !important;
    --card-border: rgba(255, 255, 255, 0.2);
}

/* Extra safety for generic elements */
body,
main,
section,
article {
    color: var(--text-secondary);
}

/* Chatbot Attention Griever */
.chatbot-highlight {
    border: 2px solid var(--primary-color) !important;
    animation: pulse-glow 3s infinite ease-in-out;
}

.card-badge-pulse {
    position: absolute;
    top: 15px;
    left: 15px;
    background: linear-gradient(135deg, #FFD54F, #FFA726);
    color: #0c1e33;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 800;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(255, 167, 38, 0.3);
    animation: live-pulse 2s infinite ease-in-out;
}

.card-action-hint {
    margin-top: 15px;
    font-size: 13px;
    font-weight: 700;
    color: var(--primary-light) !important;
    opacity: 0.9;
    letter-spacing: 0.5px;
}


/* Grid & Cards System */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.premium-card {
    background: var(--card-bg);
    -webkit-backdrop-filter: blur(25px) saturate(200%);
    backdrop-filter: blur(25px) saturate(200%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    padding: 24px;
    box-shadow:
        0 15px 45px rgba(0, 0, 0, 0.2),
        inset 0 0 20px rgba(255, 255, 255, 0.05);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

/* Glass Shimmer (Continuous & Intense) */
@keyframes glimmer {
    0% {
        transform: translateX(-100%) rotate(45deg);
        opacity: 0;
    }

    5% {
        opacity: 1;
    }

    25% {
        transform: translateX(100%) rotate(45deg);
        opacity: 1;
    }

    30% {
        opacity: 0;
    }

    100% {
        transform: translateX(100%) rotate(45deg);
        opacity: 0;
    }
}

.premium-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.25),
            transparent);
    transform: skewX(-30deg);
    animation: glimmer 5s infinite ease-in-out;
    pointer-events: none;
}

.premium-card:hover {
    transform: translateY(-12px) scale(1.03);
    border-color: var(--primary-light);
    box-shadow:
        0 20px 60px rgba(59, 130, 246, 0.3),
        inset 0 0 30px rgba(255, 255, 255, 0.15);
}

/* Floating Animation */
@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0px);
    }
}

.floating-icon {
    animation: float 4s ease-in-out infinite;
}

/* Shine Animation */
@keyframes shine {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

.btn-premium {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light)) !important;
    color: white !important;
    border: none;
    padding: 14px 28px;
    border-radius: 16px;
    font-weight: 800;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.btn-premium::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.6),
            transparent);
    transform: skewX(-25deg);
    animation: shine 4s infinite;
}

/* Header & Nav */
.main-header {
    background: var(--nav-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--card-border);
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--nav-bg);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    border-top: 1px solid var(--card-border);
    display: flex;
    justify-content: space-around;
    padding: 12px 0;
    z-index: 1000;
}

.nav-item {
    text-decoration: none;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    transition: 0.2s;
}

.nav-item.active {
    color: var(--primary-color);
    font-weight: bold;
}

/* Buttons */
.btn-premium {
    background: var(--primary-color);
    color: white !important;
    border: none;
    padding: 12px 24px;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 700;
    transition: 0.3s;
    box-shadow: 0 4px 15px rgba(103, 58, 183, 0.3);
}

.btn-premium:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

/* Global Contrast & Elements visibility */
input,
select,
textarea {
    background: var(--bg-secondary) !important;
    color: var(--text-main) !important;
    border: 1px solid var(--card-border) !important;
}

label {
    color: var(--text-main) !important;
    font-weight: 600;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--text-main) !important;
}

p,
span,
div {
    /* Only apply to those that don't have specific text variables already */
    color: inherit;
}

.task-title {
    color: var(--text-main) !important;
}

.task-meta {
    color: var(--text-secondary) !important;
}

/* Ensure contrast in light mode */
[data-theme="light"] input,
[data-theme="light"] select,
[data-theme="light"] textarea {
    background: #ffffff !important;
    color: #0c1e33 !important;
}

/* Edit/Delete Button Styles */
.task-action-btn {
    padding: 8px;
    border-radius: 8px;
    transition: 0.3s;
    background: rgba(255, 255, 255, 0.05);
}

.task-action-btn.edit:hover {
    background: var(--primary-color) !important;
    color: white !important;
}

.task-action-btn.delete:hover {
    background: var(--danger-color) !important;
    color: white !important;
}

/* Viewport safety */
@media (max-width: 768px) {
    .cards-grid {
        grid-template-columns: 1fr;
        padding: 10px;
    }
}