/* ==========================================================
   PORTFOLIO — ADELEKE EMMANUEL
   styles.css
   Dark-first theme, responsive, animations
   ========================================================== */

/* ===================== CUSTOM PROPERTIES ===================== */
:root {
    /* Dark theme (default) */
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-card: #161616;
    --bg-card-hover: #1a1a1a;
    --bg-nav: rgba(10, 10, 10, 0.85);
    --text-primary: #e5e5e5;
    --text-secondary: #a0a0a0;
    --text-muted: #666666;
    --accent: #00d4aa;
    --accent-dim: rgba(0, 212, 170, 0.1);
    --accent-glow: rgba(0, 212, 170, 0.15);
    --border: #1e1e1e;
    --border-hover: #2a2a2a;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 8px 32px rgba(0, 0, 0, 0.4);
    --gradient-hero: radial-gradient(ellipse at 20% 50%, rgba(0, 212, 170, 0.06) 0%, transparent 60%);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

[data-theme="light"] {
    --bg-primary: #fafafa;
    --bg-secondary: #f0f0f0;
    --bg-card: #ffffff;
    --bg-card-hover: #f8f8f8;
    --bg-nav: rgba(250, 250, 250, 0.9);
    --text-primary: #1a1a1a;
    --text-secondary: #555555;
    --text-muted: #999999;
    --accent: #00a882;
    --accent-dim: rgba(0, 168, 130, 0.08);
    --accent-glow: rgba(0, 168, 130, 0.12);
    --border: #e0e0e0;
    --border-hover: #d0d0d0;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 8px 32px rgba(0, 0, 0, 0.1);
    --gradient-hero: radial-gradient(ellipse at 20% 50%, rgba(0, 168, 130, 0.06) 0%, transparent 60%);
}

/* ===================== RESET & BASE ===================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: var(--font);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--transition), color var(--transition);
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* ===================== CONTAINER ===================== */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===================== NAVIGATION ===================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--bg-nav);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: background-color var(--transition), border-color var(--transition);
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-logo {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    transition: color var(--transition);
}

.logo-bracket {
    color: var(--accent);
    font-weight: 300;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-link {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
    transition: color var(--transition);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--accent);
    transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Theme Toggle */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
}

.theme-toggle:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-dim);
}

[data-theme="dark"] .icon-sun {
    display: block;
}

[data-theme="dark"] .icon-moon {
    display: none;
}

[data-theme="light"] .icon-sun {
    display: none;
}

[data-theme="light"] .icon-moon {
    display: block;
}

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    width: 34px;
    height: 34px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-card);
    cursor: pointer;
    padding: 8px;
    transition: all var(--transition);
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-secondary);
    border-radius: 2px;
    transition: all var(--transition);
}

.hamburger:hover {
    border-color: var(--accent);
}

.hamburger:hover span {
    background: var(--accent);
}

.hamburger.active span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

/* ===================== HERO ===================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 120px 24px 80px;
    background: var(--gradient-hero);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 20%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: float 8s ease-in-out infinite alternate;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(-30px, -40px) scale(1.1);
    }
}

.hero-content {
    max-width: 800px;
    text-align: left;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: lowercase;
    letter-spacing: 0.04em;
    margin-bottom: 32px;
    background: var(--bg-card);
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #00cc88;
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(0, 204, 136, 0.4);
    }

    50% {
        opacity: 0.8;
        box-shadow: 0 0 0 6px rgba(0, 204, 136, 0);
    }
}

.hero-name {
    font-size: clamp(3rem, 8vw, 5.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.04em;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.accent-dot {
    color: var(--accent);
}

.hero-title {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 20px;
    letter-spacing: 0.02em;
}

.hero-tagline {
    font-size: 1.1rem;
    font-weight: 300;
    color: var(--text-secondary);
    max-width: 550px;
    line-height: 1.8;
    margin-bottom: 36px;
}

.highlight {
    color: var(--text-primary);
    font-weight: 500;
}

.hero-socials {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-secondary);
    background: var(--bg-card);
    transition: all var(--transition);
}

.social-link:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: var(--accent-dim);
    transform: translateY(-2px);
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.02em;
    transition: color var(--transition);
}

.hero-cta:hover {
    color: var(--accent);
}

.hero-cta svg {
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(4px);
    }
}

/* Scroll indicator */
.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--accent), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {

    0%,
    100% {
        opacity: 0.3;
    }

    50% {
        opacity: 1;
    }
}

/* ===================== SECTIONS ===================== */
.section {
    padding: 120px 0;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 48px;
}

.section-number {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent);
    font-variant-numeric: tabular-nums;
}

.section-title {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.section-line {
    flex: 1;
    height: 1px;
    background: var(--border);
}

.section-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 48px;
    line-height: 1.7;
}

/* ===================== ABOUT ===================== */
.about-top {
    display: flex;
    gap: 56px;
    align-items: center;
    margin-bottom: 56px;
}

.about-left {
    flex-shrink: 0;
}

.about-image-wrapper {
    position: relative;
    width: 280px;
    height: 340px;
}

.about-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px;
    filter: grayscale(30%);
    transition: filter var(--transition);
}

.about-image:hover {
    filter: grayscale(0%);
}

.image-border-accent {
    position: absolute;
    top: 12px;
    left: 12px;
    right: -12px;
    bottom: -12px;
    border: 1px solid var(--border-hover);
    border-radius: 16px;
    z-index: -1;
    transition: all var(--transition);
}

.about-image-wrapper:hover .image-border-accent {
    top: 8px;
    left: 8px;
    right: -8px;
    bottom: -8px;
    border-color: var(--accent);
}

.about-right {
    flex: 1;
    min-width: 0;
}

.about-greeting {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 8px;
    line-height: 1.3;
}

.about-name {
    color: var(--accent);
}

.about-role {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}

.about-bio p {
    color: var(--text-secondary);
    margin-bottom: 14px;
    font-size: 0.95rem;
    line-height: 1.8;
}

.about-bio strong {
    color: var(--text-primary);
    font-weight: 600;
}

.about-resume-cta {
    margin-top: 28px;
}

.about-resume-cta .btn-outline {
    font-size: 0.85rem;
    padding: 10px 22px;
}

.about-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.detail-card {
    padding: 28px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: all var(--transition);
    text-align: center;
}

.detail-card:hover {
    border-color: var(--accent);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.detail-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-dim);
    border-radius: 14px;
    color: var(--accent);
    margin: 0 auto 16px;
}

.detail-card h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.detail-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ===================== SKILLS ===================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 16px;
}

.skill-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 28px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: all var(--transition);
    cursor: default;
}

.skill-item:hover {
    border-color: var(--accent);
    background: var(--accent-dim);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.skill-item i {
    font-size: 40px;
}

.skill-item .skill-svg {
    color: var(--accent);
}

.skill-item span {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-align: center;
}

.skill-item:hover span {
    color: var(--text-primary);
}

/* GitHub icon in dark mode needs special handling */
[data-theme="dark"] .devicon-github-original {
    color: var(--text-secondary);
}

[data-theme="light"] .devicon-github-original {
    color: #333;
}

/* ===================== PROJECTS ===================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 48px;
}

.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
    opacity: 0;
    transition: opacity var(--transition);
}

.project-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.project-card:hover::before {
    opacity: 1;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.project-folder {
    color: var(--accent);
}

.project-links a {
    color: var(--text-muted);
    transition: color var(--transition);
}

.project-links a:hover {
    color: var(--accent);
}

.project-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.project-description {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
    flex: 1;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-tags span {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--accent);
    padding: 4px 12px;
    background: var(--accent-dim);
    border-radius: 100px;
    letter-spacing: 0.02em;
}

.projects-cta {
    text-align: center;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition);
    font-family: var(--font);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-dim);
}

/* ===================== CONTACT ===================== */
.contact-content {
    text-align: center;
    max-width: 560px;
    margin: 0 auto;
}

.contact-text {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 36px;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 36px;
    background: var(--accent);
    color: #0a0a0a;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font);
    transition: all var(--transition);
    margin-bottom: 40px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 212, 170, 0.3);
}

.contact-socials {
    display: flex;
    justify-content: center;
    gap: 24px;
}

.contact-socials a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color var(--transition);
}

.contact-socials a:hover {
    color: var(--accent);
}

/* ===================== FOOTER ===================== */
.footer {
    padding: 40px 0;
    border-top: 1px solid var(--border);
}

.footer-content {
    text-align: center;
}

.footer-text {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.footer-text strong {
    color: var(--text-primary);
}

.footer-copy {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ===================== ANIMATIONS ===================== */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--bg-nav);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        align-items: center;
        gap: 0;
        padding: 16px 0;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: all var(--transition);
    }

    .nav-links.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
    }

    .nav-link {
        display: block;
        padding: 12px 24px;
        font-size: 1rem;
    }

    .nav-link::after {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero {
        padding: 100px 24px 60px;
    }

    .hero-name {
        font-size: clamp(2.4rem, 10vw, 3.5rem);
    }

    .hero-tagline {
        font-size: 1rem;
    }

    .section {
        padding: 80px 0;
    }

    .about-top {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .about-left {
        display: flex;
        justify-content: center;
    }

    .about-image-wrapper {
        width: 220px;
        height: 270px;
    }

    .about-greeting {
        font-size: 1.3rem;
    }

    .about-role {
        font-size: 0.8rem;
    }

    .about-bio p {
        text-align: left;
    }

    .about-resume-cta {
        text-align: center;
    }

    .about-details {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 12px;
    }

    .skill-item {
        padding: 20px 12px;
    }

    .skill-item i {
        font-size: 32px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-socials {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero-name {
        font-size: 2.2rem;
    }

    .hero-socials {
        gap: 10px;
    }

    .social-link {
        width: 40px;
        height: 40px;
    }

    .section-title {
        font-size: 1.3rem;
    }

    .project-card {
        padding: 20px;
    }
}