/**
 * DevWharf Resume Page Styles
 * Cyberpunk-inspired professional resume layout
 * Uses theme variables from base.css
 *
 * @since 5.2.0
 */

/* ===================================================================
   RESUME PAGE — Layout & Structure
   =================================================================== */

.dw-resume-page {
    position: relative;
    overflow: hidden;
    background: var(--dw-bg-primary);
}

/* Subtle animated grid backdrop for the entire resume */
.dw-resume-page::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.03;
    background-image:
        linear-gradient(rgba(99, 102, 241, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(99, 102, 241, 0.08) 1px, transparent 1px);
    background-size: 40px 40px;
}

.dw-resume-container {
    position: relative;
    z-index: 1;
    max-width: 960px;
    margin: 0 auto;
    padding: 0 clamp(20px, 5vw, 60px);
}

/* ===================================================================
   HEADER HERO — Name, Contact, Summary
   =================================================================== */

.dw-resume-hero {
    padding: clamp(100px, 14vh, 180px) 0 clamp(40px, 6vh, 80px);
    text-align: center;
    position: relative;
}

/* Decorative glow behind the hero */
.dw-resume-hero::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(
        ellipse at center,
        rgba(99, 102, 241, 0.08) 0%,
        rgba(139, 92, 246, 0.04) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: -1;
}

.dw-resume-name {
    font-family: var(--dw-font-display) !important;
    font-size: clamp(2.8rem, 7vw, 5rem) !important;
    font-weight: 800 !important;
    letter-spacing: -0.03em !important;
    line-height: 1.1 !important;
    margin: 0 0 20px !important;
    color: var(--dw-text-primary) !important;
    /* Subtle gradient text effect */
    background: linear-gradient(135deg, #f0f0f0 0%, #c8c8dc 50%, #f0f0f0 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Contact info bar */
.dw-resume-contact {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 20px;
    margin-bottom: 36px;
    font-family: var(--dw-font-mono) !important;
    font-size: 0.85rem;
    color: var(--dw-text-muted);
}

.dw-resume-contact a {
    color: var(--dw-accent-cyan) !important;
    text-decoration: none !important;
    transition: color 0.3s ease;
}

.dw-resume-contact a:hover {
    color: var(--dw-accent-indigo) !important;
}

.dw-resume-contact-sep {
    color: rgba(99, 102, 241, 0.3);
    user-select: none;
}

/* Professional summary */
.dw-resume-summary {
    max-width: 760px;
    margin: 0 auto;
    font-family: var(--dw-font-body) !important;
    font-size: clamp(1rem, 2vw, 1.15rem) !important;
    line-height: 1.8 !important;
    color: var(--dw-text-secondary) !important;
    text-align: left;
    padding: 28px 32px;
    background: rgba(12, 12, 20, 0.6);
    border: 1px solid var(--dw-border);
    border-radius: 12px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* ===================================================================
   SECTION HEADINGS
   =================================================================== */

.dw-resume-section {
    margin-bottom: clamp(40px, 6vh, 72px);
    /* Fade-in on load via scroll animation classes */
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.dw-resume-section.dw-revealed {
    opacity: 1;
    transform: translateY(0);
}

.dw-resume-section-heading {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px !important;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--dw-border);
    font-family: var(--dw-font-display) !important;
    font-size: clamp(1.4rem, 3vw, 1.8rem) !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
    color: var(--dw-text-primary) !important;
}

.dw-resume-section-heading .material-symbols-outlined {
    font-size: 1.6rem !important;
    filter: drop-shadow(0 0 8px currentColor);
}

/* Per-section accent colors on heading icon */
.dw-resume-section[data-accent="emerald"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-emerald); }
.dw-resume-section[data-accent="cyan"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-cyan); }
.dw-resume-section[data-accent="violet"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-violet); }
.dw-resume-section[data-accent="amber"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-amber); }
.dw-resume-section[data-accent="indigo"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-indigo); }
.dw-resume-section[data-accent="rose"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-rose); }
.dw-resume-section[data-accent="blue"] .dw-resume-section-heading .material-symbols-outlined { color: var(--dw-accent-blue); }

/* Accent bar on section heading border */
.dw-resume-section[data-accent="emerald"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-emerald), transparent) 1; }
.dw-resume-section[data-accent="cyan"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-cyan), transparent) 1; }
.dw-resume-section[data-accent="violet"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-violet), transparent) 1; }
.dw-resume-section[data-accent="amber"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-amber), transparent) 1; }
.dw-resume-section[data-accent="indigo"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-indigo), transparent) 1; }
.dw-resume-section[data-accent="rose"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-rose), transparent) 1; }
.dw-resume-section[data-accent="blue"] .dw-resume-section-heading { border-image: linear-gradient(to right, var(--dw-accent-blue), transparent) 1; }

/* ===================================================================
   SKILLS — Tag Grid
   =================================================================== */

.dw-resume-skills-category {
    margin-bottom: 20px;
}

.dw-resume-skills-label {
    font-family: var(--dw-font-mono) !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--dw-text-muted);
    margin-bottom: 10px !important;
}

.dw-resume-skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.dw-resume-skill-tag {
    display: inline-block;
    padding: 6px 14px;
    font-family: var(--dw-font-body) !important;
    font-size: 0.85rem;
    color: var(--dw-text-secondary);
    background: rgba(99, 102, 241, 0.06);
    border: 1px solid rgba(99, 102, 241, 0.12);
    border-radius: 6px;
    transition: all 0.3s ease;
    cursor: default;
}

.dw-resume-skill-tag:hover {
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.25);
    color: var(--dw-text-primary);
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.08);
}

/* ===================================================================
   EXPERIENCE — Timeline Cards
   =================================================================== */

.dw-resume-experience-item {
    position: relative;
    padding: 24px 28px;
    margin-bottom: 20px;
    background: rgba(12, 12, 20, 0.5);
    border: 1px solid var(--dw-border);
    border-radius: 12px;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    transition: border-color 0.4s ease, box-shadow 0.4s ease;
}

.dw-resume-experience-item:hover {
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.05);
}

/* Left accent bar */
.dw-resume-experience-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 16px;
    bottom: 16px;
    width: 3px;
    border-radius: 3px;
    background: var(--item-accent, var(--dw-accent-indigo));
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.dw-resume-experience-item:hover::before {
    opacity: 1;
}

.dw-resume-exp-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 6px;
}

.dw-resume-exp-company {
    font-family: var(--dw-font-display) !important;
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    color: var(--dw-text-primary) !important;
    margin: 0 !important;
}

.dw-resume-exp-dates {
    font-family: var(--dw-font-mono) !important;
    font-size: 0.8rem;
    color: var(--dw-text-muted);
    white-space: nowrap;
    padding: 4px 10px;
    background: rgba(99, 102, 241, 0.06);
    border-radius: 4px;
}

.dw-resume-exp-title {
    font-family: var(--dw-font-body) !important;
    font-size: 0.95rem !important;
    font-style: italic;
    color: var(--dw-accent-cyan) !important;
    margin: 0 0 14px !important;
}

.dw-resume-exp-location {
    color: var(--dw-text-muted);
    font-style: normal;
}

.dw-resume-exp-bullets {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.dw-resume-exp-bullets li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
    font-family: var(--dw-font-body) !important;
    font-size: 0.95rem !important;
    line-height: 1.7 !important;
    color: var(--dw-text-secondary) !important;
}

/* Custom bullet: small neon dot */
.dw-resume-exp-bullets li::before {
    content: '';
    position: absolute;
    left: 2px;
    top: 10px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--item-accent, var(--dw-accent-indigo));
    box-shadow: 0 0 6px var(--item-accent, rgba(99, 102, 241, 0.5));
}

/* ===================================================================
   PROJECTS — Glass Cards Grid
   =================================================================== */

.dw-resume-projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.dw-resume-project-card {
    padding: 24px;
    background: rgba(12, 12, 20, 0.55);
    border: 1px solid var(--dw-border);
    border-radius: 12px;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    transition: border-color 0.4s ease, box-shadow 0.4s ease, transform 0.4s ease;
}

.dw-resume-project-card:hover {
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 0 24px rgba(99, 102, 241, 0.06);
    transform: translateY(-2px);
}

.dw-resume-project-name {
    font-family: var(--dw-font-display) !important;
    font-size: 1.15rem !important;
    font-weight: 700 !important;
    color: var(--dw-text-primary) !important;
    margin: 0 0 6px !important;
}

.dw-resume-project-stack {
    font-family: var(--dw-font-mono) !important;
    font-size: 0.72rem;
    color: var(--dw-accent-cyan);
    margin-bottom: 10px;
    letter-spacing: 0.02em;
}

.dw-resume-project-desc {
    font-family: var(--dw-font-body) !important;
    font-size: 0.9rem !important;
    line-height: 1.7 !important;
    color: var(--dw-text-secondary) !important;
    margin: 0 !important;
}

/* ===================================================================
   EDUCATION — Clean Card
   =================================================================== */

.dw-resume-edu-item {
    padding: 24px 28px;
    margin-bottom: 16px;
    background: rgba(12, 12, 20, 0.5);
    border: 1px solid var(--dw-border);
    border-radius: 12px;
}

.dw-resume-edu-degree {
    font-family: var(--dw-font-display) !important;
    font-size: 1.15rem !important;
    font-weight: 700 !important;
    color: var(--dw-text-primary) !important;
    margin: 0 0 4px !important;
}

.dw-resume-edu-school {
    font-family: var(--dw-font-body) !important;
    font-size: 0.95rem;
    color: var(--dw-accent-cyan);
    margin-bottom: 10px;
}

.dw-resume-edu-detail {
    font-family: var(--dw-font-body) !important;
    font-size: 0.9rem !important;
    line-height: 1.7 !important;
    color: var(--dw-text-secondary) !important;
    margin: 0 0 6px !important;
}

/* ===================================================================
   DOWNLOAD / PRINT BUTTON
   =================================================================== */

.dw-resume-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    padding: 40px 0 clamp(60px, 10vh, 120px);
}



/* ===================================================================
   SCROLL REVEAL — IntersectionObserver driven
   =================================================================== */

/* Each section starts hidden and slides up on intersection */
@media (prefers-reduced-motion: no-preference) {
    .dw-resume-section {
        opacity: 0;
        transform: translateY(24px);
    }

    .dw-resume-section.dw-revealed {
        opacity: 1;
        transform: translateY(0);
    }

    /* Stagger children within projects grid */
    .dw-resume-project-card {
        opacity: 0;
        transform: translateY(16px);
        transition: opacity 0.5s ease, transform 0.5s ease;
    }

    .dw-revealed .dw-resume-project-card {
        opacity: 1;
        transform: translateY(0);
    }

    .dw-revealed .dw-resume-project-card:nth-child(1) { transition-delay: 0.05s; }
    .dw-revealed .dw-resume-project-card:nth-child(2) { transition-delay: 0.1s; }
    .dw-revealed .dw-resume-project-card:nth-child(3) { transition-delay: 0.15s; }
    .dw-revealed .dw-resume-project-card:nth-child(4) { transition-delay: 0.2s; }
    .dw-revealed .dw-resume-project-card:nth-child(5) { transition-delay: 0.25s; }
    .dw-revealed .dw-resume-project-card:nth-child(6) { transition-delay: 0.3s; }
    .dw-revealed .dw-resume-project-card:nth-child(7) { transition-delay: 0.35s; }
    .dw-revealed .dw-resume-project-card:nth-child(8) { transition-delay: 0.4s; }
}

/* ===================================================================
   RESPONSIVE — Mobile Overrides
   =================================================================== */

@media (max-width: 640px) {
    .dw-resume-hero {
        padding: clamp(80px, 12vh, 140px) 0 30px;
    }

    .dw-resume-contact {
        flex-direction: column;
        align-items: center;
        gap: 6px;
    }

    .dw-resume-contact-sep {
        display: none;
    }

    .dw-resume-summary {
        padding: 20px;
    }

    .dw-resume-exp-header {
        flex-direction: column;
    }

    .dw-resume-projects-grid {
        grid-template-columns: 1fr;
    }

    .dw-resume-experience-item {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .dw-resume-name {
        font-size: 2.2rem !important;
    }

    .dw-resume-section-heading {
        font-size: 1.3rem !important;
    }

    .dw-resume-skill-tag {
        font-size: 0.78rem;
        padding: 5px 10px;
    }
}


/* ===================================================================
   SOCIAL ICONS ROW — Centered between contact bar and summary
   Reuses .dw-social-icon from footer.css for consistent hover states
   =================================================================== */

.dw-resume-socials {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-bottom: 28px;
}

/* ===================================================================
   LIQUID MORPH BUTTONS — Organic blob hover for resume CTA row
   =================================================================== */

.btn-liquid-morph {
    position: relative;
    background: #1e293b;
    color: #fff;
    border: 1px solid #475569;
    padding: 1rem 2rem;
    border-radius: 999px;
    font-family: var(--dw-font-body) !important;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    overflow: hidden;
    z-index: 1;
    transition: color 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-liquid-morph::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 150px;
    background: #6366f1;
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    transform: translate(-50%, -50%) scale(0.1);
    opacity: 0;
    z-index: -1;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s;
    animation: morphSlow 4s linear infinite;
}

.btn-liquid-morph:hover {
    border-color: #6366f1;
    color: #fff;
}

.btn-liquid-morph:hover::before {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 1;
}

@keyframes morphSlow {
    0%, 100% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; }
    34% { border-radius: 70% 30% 50% 50% / 30% 30% 70% 70%; }
    67% { border-radius: 100% 60% 60% 100% / 100% 100% 60% 60%; }
}
