/* ============================================
   Swan Htet Naing — Portfolio (Modern UI)
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: #1a1a25;
    --bg-card-hover: #22222f;
    --accent: #3b82f6;
    --accent-light: #60a5fa;
    --accent-glow: rgba(59, 130, 246, 0.15);
    --accent-glow-strong: rgba(59, 130, 246, 0.3);
    --text-primary: #f0f0f5;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --border: #1e1e2e;
    --border-light: #2a2a3a;
    --success: #22c55e;
    --accent-solid: #3b82f6;
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.4);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: auto;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* ---- Header ---- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 72px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 48px;
    z-index: 1000;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}

.header-logo {
    display: flex;
    align-items: center;
}

.header-logo img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 8px;
}

nav ul li a {
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

nav ul li a:hover {
    color: var(--text-primary);
    background: var(--accent-glow);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn-hire {
    padding: 10px 24px;
    background: var(--accent);
    color: white;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-hire:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px var(--accent-glow-strong);
}

.menubtn {
    display: none;
    cursor: pointer;
    font-size: 22px;
    color: var(--accent);
}

/* ---- Hero ---- */
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 48px 40px;
    max-width: 1300px;
    margin: 0 auto;
    gap: 60px;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 50px;
    font-size: 13px;
    font-weight: 500;
    color: var(--success);
    margin-bottom: 24px;
}

.hero-badge::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.hero-greeting {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.hero-name {
    font-size: 52px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 12px;
    letter-spacing: -1px;
}

.hero-title {
    font-size: 22px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 20px;
}

.hero-desc {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 32px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
}

.btn-primary {
    padding: 12px 32px;
    background: var(--accent);
    color: white;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px var(--accent-glow-strong);
}

.btn-outline {
    padding: 12px 32px;
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-outline:hover {
    border-color: var(--accent);
    background: var(--accent-glow);
}

.hero-socials {
    display: flex;
    gap: 12px;
}

.hero-socials a {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-light);
    border-radius: 50%;
    font-size: 18px;
    color: var(--text-secondary);
    transition: var(--transition);
}

.hero-socials a:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-glow);
    transform: translateY(-2px);
}

.hero-image {
    flex: 0 0 auto;
}

.hero-img-wrapper {
    position: relative;
}

.hero-img-wrapper img {
    width: 320px;
    height: 320px;
    object-fit: cover;
    border-radius: 24px;
    position: relative;
    z-index: 2;
    box-shadow: var(--shadow-lg);
}

.hero-img-decoration {
    position: absolute;
    inset: -12px;
    border-radius: 28px;
    background: var(--accent);
    opacity: 0.25;
    z-index: 1;
    filter: blur(2px);
}

/* ---- Sections ---- */
.section {
    padding: 40px 48px;
    max-width: 1300px;
    margin: 0 auto;
}

.section-dark {
    background: var(--bg-secondary);
    max-width: 100%;
    padding-left: 0;
    padding-right: 0;
}

.section-dark > * {
    max-width: 1300px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 48px;
    padding-right: 48px;
}

/* Reset padding on timeline so dot aligns with the vertical line */
.section-dark .timeline {
    padding-left: 0;
    padding-right: 0;
}

.section-header {
    text-align: center;
    margin-bottom: 32px;
}

.section-tag {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent);
    margin-bottom: 12px;
}

.section-title {
    font-size: 36px;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.accent {
    color: var(--accent);
}

/* ---- About ---- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.about-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
}

.about-card-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.info-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.status-available {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--success);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse 2s infinite;
}

.about-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 24px;
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 30px var(--accent-glow);
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

/* ---- Skills — Inverted Pyramid ---- */
.pyramid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 0 30px;
}

.pyramid-row {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 10px;
    flex-wrap: nowrap;
    width: 100%;
    max-width: 1200px;
}

.pyramid-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px 6px 10px;
    background: rgba(59, 130, 246, 0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: var(--transition);
    cursor: default;
    width: 78px;
    flex-shrink: 0;
}

.pyramid-item:hover {
    border-color: var(--accent);
    background: var(--accent-glow);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.15);
}

.pyramid-item img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    opacity: 0.9;
    transition: var(--transition);
}

.pyramid-item:hover img {
    opacity: 1;
    transform: scale(1.15);
}

.pyramid-item span {
    font-size: 9px;
    font-weight: 500;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.pyramid-item:hover span {
    color: var(--text-primary);
}

.skill-cat-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--accent);
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 50px;
    flex-shrink: 0;
    height: 28px;
    align-self: center;
}

/* ---- Timeline ---- */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

/* Animated vertical line — fills with gradient as you scroll */
.timeline::before {
    content: "";
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-light);
}

.timeline::after {
    content: "";
    position: absolute;
    left: 20px;
    top: 0;
    width: 2px;
    height: 0%;
    background: linear-gradient(180deg, var(--accent), #8b5cf6, var(--accent));
    background-size: 100% 200%;
    animation: lineShift 3s ease infinite;
    transition: height 0.1s linear;
    z-index: 1;
    border-radius: 2px;
    box-shadow: 0 0 12px var(--accent-glow-strong), 0 0 24px var(--accent-glow);
}

@keyframes lineShift {
    0%   { background-position: 0% 0%; }
    50%  { background-position: 0% 100%; }
    100% { background-position: 0% 0%; }
}

/* ===== Traveler dot — glides down the line as you scroll ===== */
.tl-traveler {
    position: sticky;
    top: 80px;
    z-index: 10;
    height: 0;
    overflow: visible;
    pointer-events: none;
}

.traveler-dot {
    position: absolute;
    left: 12px;
    top: -9px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--bg-primary);
    z-index: 12;
    opacity: 0;
    transform: scale(0.6);
    transition: opacity 0.4s ease, transform 0.4s ease, background 0.4s ease;
    /* Glow ring */
    box-shadow: 0 0 0 0 var(--accent-glow-strong),
                0 0 16px 2px var(--accent-glow);
}

.tl-traveler.tl-visible .traveler-dot {
    opacity: 1;
    transform: scale(1);
    animation: travelerPulse 1.6s ease-in-out infinite;
}

@keyframes travelerPulse {
    0%, 100% { box-shadow: 0 0 0 0 var(--accent-glow-strong), 0 0 16px 2px var(--accent-glow); }
    50%      { box-shadow: 0 0 0 10px rgba(59,130,246,0), 0 0 24px 4px rgba(59,130,246,0.1); }
}

.traveler-dot.dot-education {
    background: #8b5cf6;
}

.tl-traveler.tl-visible .dot-education {
    animation: travelerPulsePurple 1.6s ease-in-out infinite;
}

@keyframes travelerPulsePurple {
    0%, 100% { box-shadow: 0 0 0 0 rgba(139,92,246,0.4), 0 0 16px 2px rgba(139,92,246,0.2); }
    50%      { box-shadow: 0 0 0 10px rgba(139,92,246,0), 0 0 24px 4px rgba(139,92,246,0.1); }
}

/* ===== Per-card dot — revealed by scroll when card passes traveler ===== */
.timeline-dot {
    position: absolute;
    left: 12px;
    top: 4px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--bg-primary);
    z-index: 2;
    transform: scale(0);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
                opacity 0.3s ease;
}

/* When card is in view AND not hidden by scroll listener, show dot */
.timeline-item.tl-visible .timeline-dot {
    transform: scale(1);
    opacity: 1;
    animation: cardDotGlow 2.5s ease-in-out 0.4s infinite;
}

@keyframes cardDotGlow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(59,130,246,0.25); }
    50%      { box-shadow: 0 0 0 6px rgba(59,130,246,0); }
}

.dot-education {
    background: #8b5cf6;
}

.timeline-item.tl-visible .dot-education {
    animation: cardDotGlowPurple 2.5s ease-in-out infinite 0.4s;
}

@keyframes cardDotGlowPurple {
    0%, 100% { box-shadow: 0 0 0 0 rgba(139,92,246,0.3); }
    50%      { box-shadow: 0 0 0 6px rgba(139,92,246,0); }
}

/* Each item slides in when scrolled into view */
.timeline-item {
    position: relative;
    padding-left: 56px;
    padding-bottom: 40px;
    opacity: 0;
    transform: translateX(-40px) scale(0.97);
    transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.timeline-item:nth-child(2) { transition-delay: 0s; }
.timeline-item:nth-child(3) { transition-delay: 0.12s; }
.timeline-item:nth-child(4) { transition-delay: 0.24s; }
.timeline-item:nth-child(5) { transition-delay: 0.36s; }

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item.tl-visible {
    opacity: 1;
    transform: translateX(0) scale(1);
}

/* Content card — subtle lift on reveal */
.timeline-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-item.tl-visible .timeline-content {
    border-color: rgba(59, 130, 246, 0.15);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.timeline-content:hover {
    border-color: var(--accent);
    transform: translateX(6px);
    box-shadow: 0 8px 32px var(--accent-glow);
}

.timeline-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--accent-glow);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-light);
    margin-bottom: 12px;
}

.timeline-role {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
}

.timeline-company {
    font-size: 14px;
    font-weight: 500;
    color: var(--accent);
    margin-bottom: 12px;
}

.timeline-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ---- Projects (Scroll Slideshow) ---- */
.slideshow-wrapper {
    height: 500vh;
    overflow-x: clip;
    position: relative;
}

.slideshow-pinned {
    position: sticky;
    top: 72px;
    height: calc(100vh - 72px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 48px;
}

.slideshow-track {
    display: flex;
    gap: 24px;
    will-change: transform;
}

.project-card {
    min-width: calc(44% - 12px);
    max-width: calc(44% - 12px);
    background: linear-gradient(145deg, var(--bg-card) 0%, rgba(30, 30, 50, 0.8) 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.35s ease,
                box-shadow 0.35s ease;
}

.project-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), #8b5cf6, var(--accent-light));
    opacity: 0;
    transition: opacity 0.35s ease;
}

.project-card:hover {
    border-color: rgba(59, 130, 246, 0.3);
    transform: translateY(-6px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4),
                0 0 40px var(--accent-glow);
}

.project-card:hover::before {
    opacity: 1;
}

.slideshow-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin-top: 32px;
    padding-bottom: 16px;
}

.slideshow-dots {
    display: none;
    gap: 10px;
}

.slideshow-dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border-light);
    transition: all 0.3s ease;
    cursor: pointer;
}

.slideshow-dots .dot.active {
    background: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow-strong);
    transform: scale(1.2);
}

.slideshow-counter {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 2px;
}

.slideshow-counter .ss-current {
    color: var(--accent);
    font-size: 20px;
}

.slideshow-counter .ss-separator {
    margin: 0 4px;
}


/* ---- Modern Project Card ---- */
.project-number {
    position: absolute;
    top: -10px;
    right: 20px;
    font-size: 120px;
    font-weight: 900;
    line-height: 1;
    color: rgba(59, 130, 246, 0.04);
    pointer-events: none;
    user-select: none;
    z-index: 0;
    transition: color 0.4s ease;
}

.project-card:hover .project-number {
    color: rgba(59, 130, 246, 0.08);
}

.project-card-body {
    position: relative;
    z-index: 1;
    padding: 32px 32px 28px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.project-meta {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}



.project-date {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

.project-name {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 14px;
    line-height: 1.3;
    letter-spacing: -0.3px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 24px;
    flex: 1;
}

.project-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.project-stack span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    background: rgba(59, 130, 246, 0.06);
    border: 1px solid rgba(59, 130, 246, 0.12);
    border-radius: 50px;
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-light);
    letter-spacing: 0.2px;
    transition: all 0.2s ease;
}

.project-stack span img {
    width: 14px;
    height: 14px;
    object-fit: contain;
    flex-shrink: 0;
}

.project-stack span:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.3);
    transform: translateY(-1px);
}


.project-label {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-left: 4px;
}

.project-label.freelance {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.25);
    color: #22c55e;
}

.project-label.company {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.25);
    color: #60a5fa;
}

.
.project-highlights {
    list-style: none;
    padding: 0;
    margin: 0 0 4px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.project-highlights li {
    list-style: none;
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
    padding-left: 16px;
    position: relative;
}

.project-highlights li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 6px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent);
    opacity: 0.6;
}

.
.contact-intro {
    text-align: center;
    max-width: 500px;
    margin: 0 auto 40px;
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.8;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
}

.contact-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 30px var(--accent-glow);
}

.contact-icon {
    font-size: 28px;
    color: var(--accent);
    margin-bottom: 12px;
}

.contact-card h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.contact-card p {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

/* ---- Footer ---- */
.footer {
    text-align: center;
    padding: 24px 0;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 13px;
}

/* ---- Animations ---- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Timeline line progress is driven by JS — fallback for no-JS */
.timeline[data-line-progress]::after {
    height: var(--line-pct, 0%);
}

/* ---- Responsive ---- */
/* ===== Mobile Responsive ===== */

/* Tablet landscape / small laptop */
@media (max-width: 1024px) {
    .hero { flex-direction: column-reverse; text-align: center; padding-top: 100px; gap: 40px; }
    .hero-content { max-width: 100%; }
    .hero-buttons { justify-content: center; flex-wrap: wrap; gap: 12px; }
    .hero-socials { justify-content: center; }
    .hero-img-wrapper img { width: 220px; height: 220px; }
    .about-grid { grid-template-columns: 1fr; gap: 24px; }
    .slideshow-pinned { padding: 0 24px; }
    .project-card { min-width: calc(75% - 12px); max-width: calc(75% - 12px); }
    .pyramid-row { flex-wrap: wrap; gap: 8px; justify-content: center; }
    .pyramid-item { width: 72px; }
    .pyramid { padding: 16px 0 24px; }
}

/* Tablet portrait / large phone */
@media (max-width: 768px) {
    /* Header */
    header { padding: 0 16px; height: 60px; }
    nav {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        width: 100%;
        background: rgba(10, 10, 15, 0.97);
        backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border);
        padding: 16px;
    }
    nav ul { flex-direction: column; align-items: center; gap: 4px; }
    nav ul li a { padding: 10px 20px; font-size: 15px; }
    .show { display: flex; }
    .menubtn { display: block; font-size: 20px; }
    .btn-hire { display: none; }

    /* Hero */
    .hero { padding: 80px 16px 32px; gap: 32px; min-height: auto; }
    .hero-badge { font-size: 12px; padding: 5px 12px; margin-bottom: 16px; }
    .hero-greeting { font-size: 14px; }
    .hero-name { font-size: 32px; line-height: 1.15; margin-bottom: 8px; }
    .hero-title { font-size: 18px; margin-bottom: 16px; }
    .hero-desc { font-size: 14px; line-height: 1.7; margin-bottom: 24px; }
    .hero-buttons { margin-bottom: 24px; }
    .hero-buttons a { padding: 10px 24px; font-size: 13px; }
    .hero-socials a { width: 40px; height: 40px; font-size: 16px; }
    .hero-img-wrapper img { width: 180px; height: 180px; border-radius: 20px; }
    .hero-img-decoration { inset: -8px; border-radius: 24px; }

    /* Sections */
    .section, .section-dark > * { padding: 48px 16px 48px; }
    .section-header { margin-bottom: 32px; }
    .section-tag { font-size: 12px; letter-spacing: 1.5px; margin-bottom: 8px; }
    .section-title { font-size: 26px; letter-spacing: -0.3px; }

    /* About */
    .about-grid { gap: 20px; }
    .about-info-card { padding: 24px; }
    .about-card-title { font-size: 18px; margin-bottom: 16px; }
    .info-grid { grid-template-columns: 1fr; gap: 12px; }
    .info-item { gap: 2px; }
    .info-label { font-size: 11px; }
    .info-value { font-size: 13px; }
    .about-stats { grid-template-columns: 1fr 1fr; gap: 12px; }
    .stat-card { padding: 20px 16px; }
    .stat-number { font-size: 28px; margin-bottom: 4px; }
    .stat-label { font-size: 12px; }

    /* Skills */
    .pyramid { padding: 12px 0 20px; gap: 8px; }
    .pyramid-row { flex-wrap: wrap; gap: 6px; justify-content: center; }
    .pyramid-item { width: 60px; padding: 8px 4px 6px; }
    .pyramid-item img { width: 24px; height: 24px; }
    .pyramid-item span { font-size: 8px; }
    .skill-cat-label { font-size: 9px; padding: 3px 10px; height: 24px; margin-bottom: 4px; }

    /* Timeline */
    .timeline { max-width: 100%; }
    .timeline::before { left: 14px; }
    .timeline::after { left: 14px; }
    .timeline-item { padding-left: 40px; padding-bottom: 28px; }
    .timeline-dot { left: 6px; }
    .traveler-dot { left: 6px; }
    .tl-traveler { top: 60px; }
    .timeline-content { padding: 16px; }
    .timeline-badge { font-size: 11px; padding: 3px 10px; margin-bottom: 8px; }
    .timeline-role { font-size: 15px; }
    .timeline-company { font-size: 13px; margin-bottom: 8px; }
    .timeline-desc { font-size: 13px; line-height: 1.6; }

    /* Slideshow */
    .slideshow-wrapper { height: 350vh; }
    .slideshow-pinned { padding: 0 12px; top: 60px; height: calc(100vh - 60px); }
    .project-card { min-width: calc(85% - 12px); max-width: calc(85% - 12px); }
    .project-card-body { padding: 20px 20px 16px; }
    .project-meta { gap: 8px; margin-bottom: 10px; }
    .project-date { font-size: 11px; }
    .project-label { font-size: 9px; padding: 2px 8px; }
    .project-name { font-size: 18px; margin-bottom: 10px; }
    .project-desc { font-size: 13px; line-height: 1.65; margin-bottom: 16px; }
    .project-highlights { gap: 5px; }
    .project-highlights li { font-size: 11px; line-height: 1.4; padding-left: 14px; }
    .project-highlights li::before { width: 4px; height: 4px; top: 5px; }
    .project-stack { gap: 5px; padding-top: 12px; }
    .project-stack span { font-size: 10px; padding: 3px 10px; gap: 4px; }
    .project-stack span img { width: 12px; height: 12px; }
    .project-number { font-size: 80px; }
    .slideshow-controls { gap: 16px; margin-top: 20px; padding-bottom: 8px; }
    .slideshow-dots { gap: 8px; }
    .slideshow-dots .dot { width: 8px; height: 8px; }
    .slideshow-counter { font-size: 13px; }

    /* Contact */
    .contact-intro { font-size: 14px; margin-bottom: 24px; }
    .contact-grid { grid-template-columns: 1fr; gap: 12px; }
    .contact-card { padding: 20px; }
    .contact-icon { font-size: 24px; margin-bottom: 8px; }
    .contact-card h3 { font-size: 13px; }
    .contact-card p { font-size: 13px; }

    /* Footer */
    .footer { padding: 16px 0; font-size: 12px; }
}

/* Small phone */
@media (max-width: 480px) {
    .hero { padding: 72px 12px 24px; gap: 24px; }
    .hero-name { font-size: 26px; }
    .hero-title { font-size: 16px; }
    .hero-desc { font-size: 13px; }
    .hero-buttons { flex-direction: column; align-items: center; }
    .hero-buttons a { width: 100%; text-align: center; }
    .hero-img-wrapper img { width: 150px; height: 150px; }

    .section, .section-dark > * { padding: 36px 12px 36px; }
    .section-title { font-size: 22px; }
    .section-header { margin-bottom: 24px; }
    .section-tag { font-size: 11px; }

    .about-info-card { padding: 20px; }
    .stat-card { padding: 16px 12px; }
    .stat-number { font-size: 24px; }
    .stat-label { font-size: 11px; }

    .pyramid { padding: 8px 0 16px; gap: 6px; }
    .pyramid-row { gap: 4px; }
    .pyramid-item { width: 52px; padding: 6px 2px 4px; }
    .pyramid-item img { width: 20px; height: 20px; }
    .pyramid-item span { font-size: 7px; }
    .skill-cat-label { font-size: 8px; padding: 2px 8px; height: 22px; }

    .timeline-item { padding-left: 36px; padding-bottom: 24px; }
    .timeline-content { padding: 14px; }
    .timeline-role { font-size: 14px; }
    .timeline-desc { font-size: 12px; }

    .slideshow-pinned { padding: 0 8px; }
    .project-card { min-width: calc(92% - 8px); max-width: calc(92% - 8px); }
    .project-card-body { padding: 16px 16px 12px; }
    .project-name { font-size: 16px; }
    .project-desc { font-size: 12px; margin-bottom: 12px; }
    .project-highlights li { font-size: 10px; }
    .project-stack { gap: 4px; padding-top: 10px; }
    .project-stack span { font-size: 9px; padding: 2px 8px; }
    .project-number { font-size: 60px; }
    .slideshow-counter .ss-current { font-size: 14px; }

    .contact-card { padding: 16px; }
    .footer { padding: 12px 0; font-size: 11px; }
}
