/* =============================================
   HSM Portfolio — Custom Styles
   ============================================= */

.editable-active {
    outline: 2px dashed #06b6d4 !important;
    background-color: rgba(6, 182, 212, 0.05);
    padding: 2px 4px;
    border-radius: 8px;
}

.project-card.hidden {
    display: none !important;
}

#node-animation-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: auto;
    z-index: 0;
    transition: background-color 0.5s ease;
}

main, header, nav, footer, #mobile-drawer {
    position: relative;
    z-index: 10;
}


/* --- Floating Profile Animation UI Effect --- */

@keyframes floatEffect {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.floating-profile-wrapper {
    animation: floatEffect 4s ease-in-out infinite;
    border-radius: 9999px; /* Force perfect circle bounds */
}


/* --- Comprehensive Day/Night Light Mode Overrides --- */

body {
    transition: color 0.5s ease, background-color 0.5s ease;
}

body.light-mode {
    background-color: #f8fafc;
    color: #0f172a;
}

body.light-mode #node-animation-canvas {
    background-color: #f8fafc;
}

body.light-mode nav {
    background-color: rgba(248, 250, 252, 0.85);
    border-color: #e2e8f0;
}

body.light-mode #mobile-drawer {
    background-color: rgba(248, 250, 252, 0.98);
    border-color: #e2e8f0;
}

/* FIXED: Vibrant High-Contrast Light Mode Transparent Gradient Name */
body.light-mode #hero-name {
    background: linear-gradient(to right, #0f172a 20%, #0369a1 65%, #083344 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    color: #0f172a; /* Fallback text color */
}

body.light-mode .card-item, 
body.light-mode .project-card {
    background-color: rgba(255, 255, 255, 0.8);
    border-color: #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

body.light-mode .card-item:hover, 
body.light-mode .project-card:hover {
    border-color: #06b6d4;
    background-color: #ffffff;
}

body.light-mode p.text-slate-400,
body.light-mode p.text-slate-500,
body.light-mode span.text-slate-400,
body.light-mode div.text-slate-400,
body.light-mode div.text-slate-500 {
    color: #475569;
}

body.light-mode h3, body.light-mode h4 {
    color: #0f172a;
}

body.light-mode ul li span, body.light-mode .text-slate-300 {
    color: #334155;
}

body.light-mode .bg-slate-900, body.light-mode .bg-slate-900\/20, body.light-mode .bg-slate-900\/50 {
    background-color: #f1f5f9;
    border-color: #cbd5e1;
}

body.light-mode input, body.light-mode textarea {
    background-color: #ffffff;
    border-color: #cbd5e1;
    color: #0f172a;
}

body.light-mode input:focus, body.light-mode textarea:focus {
    border-color: #06b6d4;
}

body.light-mode footer {
    border-color: #e2e8f0;
    background-color: #f1f5f9;
}

/* --- Print Stylesheet for Resume Download --- */
@media print {
    @page { margin: 1cm; }

    /* Hide unnecessary UI elements */
    #node-animation-canvas, nav, #mobile-drawer, .admin-ui, footer, form, .floating-profile-wrapper, .print-btn, #theme-toggle-btn, .project-link, .fa-external-link-alt, .fa-download, #stats-container, .bg-cyan-500\/10, a[href^="tel:"], #download-resume-btn {
        display: none !important;
    }

    /* Force black and white, flat styling */
    * {
        color: black !important;
        text-shadow: none !important;
        box-shadow: none !important;
        background: transparent !important;
    }

    body {
        background-color: white !important;
        color: black !important;
        display: flex !important;
        flex-direction: column !important;
    }

    /* Reset text fill for the hero name gradient */
    #hero-name {
        background: none !important;
        -webkit-text-fill-color: black !important;
        padding-top: 0 !important;
    }

    /* Reorder sections so Contact is below Header */
    #home { order: 1; padding: 0 !important; margin-bottom: 10px !important; }
    #contact-section { order: 2; border: none !important; padding: 0 !important; margin-bottom: 30px !important; }
    #main-content-wrapper { order: 3; padding: 0 !important; margin: 0 !important; }

    /* Clean up Contact Section */
    #contact-section > div > div > span,
    #contact-section > div > div > h2,
    #contact-section > div > div > p {
        display: none !important;
    }
    #contact-section .grid { display: block !important; gap: 0 !important; }
    #contact-section .space-y-3 { display: flex !important; justify-content: center !important; gap: 20px !important; flex-wrap: wrap !important; }
    #contact-section .space-y-3 > div { margin-top: 0 !important; font-size: 14px !important; }

    /* Card adjustments for print */
    .card-item {
        break-inside: avoid;
        border: 1px solid #ccc !important;
        padding: 15px !important;
        margin-bottom: 15px !important;
    }

    /* Adjust spacing */
    section { margin-bottom: 30px !important; }
    h2 { border-bottom: 2px solid black !important; padding-bottom: 5px !important; }
}
