:root {
  --primary-color: #4a4a4a; /* Negro claro profesional */
  --primary-hover: #5e5e5e;
  --bg-dark: #121212;
  --text-light: #f8f9fa;
  --transition-base: all 0.3s ease;
}

/* Base Styles */
body {
  background-color: var(--bg-dark);
  color: var(--text-light);
  padding-top: 100px;
  margin-top: 80px;
}

/* Header & Navigation */
header {
  transition: var(--transition-base);
  z-index: 1030;
}

.navbar {
  top: 60px;
  z-index: 1020;
}

.nav-link {
  position: relative;
  padding: 0.5rem 0;
  transition: var(--transition-base);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color) !important;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Hero Section */
#hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(rgba(18, 18, 18, 0.92), rgba(18, 18, 18, 0.96)), 
              url('../img/hero-bg-pattern.svg');
  background-size: cover;
}

.text-primary {
  color: var(--primary-color) !important;
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
}

/* Responsive Adjustments */
@media (max-width: 992px) {
  body {
    padding-top: 70px;
  }
  
  .navbar {
    top: 50px;
  }
  
  .nav-link {
    padding: 0.5rem 1rem;
  }
}

/* Animaciones */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-illustration {
  animation: fadeInUp 1s ease-out forwards;
}

/* About Page Styles */
.about-image {
    transition: var(--transition-base);
    border: 1px solid var(--primary-color);
}

.about-image:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.skill-item {
    transition: var(--transition-base);
}

.skill-item:hover {
    transform: translateX(5px);
}

.soft-skill-item {
    transition: var(--transition-base);
    padding: 1rem;
    border-radius: 0.5rem;
}

.soft-skill-item:hover {
    background-color: rgba(74, 74, 74, 0.1);
    transform: translateY(-3px);
}

/* Timeline Styles */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    width: 2px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: var(--primary-color);
    border-radius: 50%;
    top: 15px;
    z-index: 1;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item.left::after {
    right: -10px;
}

.timeline-item.right::after {
    left: -10px;
}

.timeline-content {
    position: relative;
}

.timeline-date {
    position: absolute;
    top: 15px;
    font-weight: bold;
    color: var(--primary-color);
}

.timeline-item.left .timeline-date {
    right: -100px;
    text-align: right;
}

.timeline-item.right .timeline-date {
    left: -100px;
    text-align: left;
}

/* Contact Page Styles */
.contact-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(74, 74, 74, 0.1);
    border-radius: 50%;
    transition: var(--transition-base);
}

.contact-icon:hover {
    background-color: rgba(74, 74, 74, 0.3);
    transform: scale(1.1);
}

#contactForm .form-control {
    transition: var(--transition-base);
}

#contactForm .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(74, 74, 74, 0.25);
}

/* Responsive Timeline */
@media (max-width: 768px) {
    .timeline::before {
        left: 40px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 0;
    }
    
    .timeline-item.left, 
    .timeline-item.right {
        left: 0;
    }
    
    .timeline-item.left::after, 
    .timeline-item.right::after {
        left: 30px;
    }
    
    .timeline-item.left .timeline-date,
    .timeline-item.right .timeline-date {
        left: 70px;
        right: auto;
        top: -25px;
        text-align: left;
    }
}

/* Projects Page Styles */
.project-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    perspective: 1000px;
}

.project-card-inner {
    transition: transform 0.6s;
    transform-style: preserve-3d;
    height: 100%;
}

.project-card:hover .project-card-inner {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.project-card img {
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid var(--primary-color);
}

.project-thumb {
    overflow: hidden;
    border-bottom: 1px solid var(--primary-color);
}

.project-thumb img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.filter-btn {
    transition: all 0.3s ease;
    min-width: 120px;
}

.filter-btn.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Modal Styles */
#projectModal .modal-content {
    border: 1px solid var(--primary-color);
}

.project-media {
    overflow: hidden;
}

.project-video-wrapper,
.project-media-img {
    max-height: 55vh;
    min-height: 260px;
}

.project-media-img {
    object-fit: cover;
}

.project-description p {
    margin-bottom: 0;
    line-height: 1.7;
}

#projectModal pre {
    max-height: 200px;
    overflow-y: auto;
}

/* Syntax Highlighting (basic) */
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
    color: #6a9955;
}

.token.punctuation {
    color: #d4d4d4;
}

.token.property,
.token.tag,
.token.boolean,
.token.number,
.token.constant,
.token.symbol,
.token.deleted {
    color: #b5cea8;
}

.token.selector,
.token.attr-name,
.token.string,
.token.char,
.token.builtin,
.token.inserted {
    color: #ce9178;
}

.token.operator,
.token.entity,
.token.url,
.language-css .token.string,
.style .token.string {
    color: #d4d4d4;
}

.token.atrule,
.token.attr-value,
.token.keyword {
    color: #569cd6;
}

.token.function,
.token.class-name {
    color: #dcdcaa;
}

.token.regex,
.token.important,
.token.variable {
    color: #d16969;
}

/* Social Links */
.social-links a {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease;
}

.social-links a:hover {
    transform: translateY(-4px) scale(1.1);
    color: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 6px 18px rgba(13, 110, 253, 0.45);
}

.social-links a i {
    font-size: 1.15rem;
}

.social-btn-lg a {
    width: 64px;
    height: 64px;
}

.social-btn-lg a i {
    font-size: 1.6rem;
}

.contact-icon + h3 {
    letter-spacing: 0.02em;
}

/* Social entrance animation */
.social-links a {
    animation: socialPop 0.6s cubic-bezier(0.2, 0.9, 0.4, 1.4) backwards;
}

.social-links a:nth-child(1) { animation-delay: 0.15s; }
.social-links a:nth-child(2) { animation-delay: 0.35s; }
.social-links a:nth-child(3) { animation-delay: 0.55s; }
.social-links a:nth-child(4) { animation-delay: 0.75s; }

@keyframes socialPop {
    0% {
        transform: scale(0) rotate(-30deg);
        opacity: 0;
        box-shadow: 0 0 0 0 rgba(13, 110, 253, 0.6);
    }
    70% {
        transform: scale(1.15) rotate(4deg);
        opacity: 1;
    }
    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
        box-shadow: 0 0 0 14px rgba(13, 110, 253, 0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .social-links a {
        animation: none;
    }
}

/* About Page */
.text-gradient {
    background: linear-gradient(120deg, #6c757d, #adb5bd);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.about-accent {
    color: #9a9a9a;
}

.about-pill {
    color: #cfd3da;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.btn-about {
    color: #e9ecef;
    background: #3a3a3a;
    border: 1px solid #5e5e5e;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.btn-about:hover {
    color: #fff;
    background: #505050;
    border-color: #7a7a7a;
    transform: translateY(-2px);
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
    opacity: 1;
    transform: none;
}

.about-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-size: 0.85rem;
    color: var(--text-light);
    opacity: 0.8;
    margin-bottom: 1rem;
}

.about-eyebrow::before {
    content: '';
    width: 36px;
    height: 2px;
    background: var(--primary-color);
}

.about-bio {
    color: #cfd3da;
}

.about-long-bio {
    line-height: 1.75;
    color: #b9bec7;
    max-height: 7.5em;
    overflow: hidden;
    position: relative;
}

.about-long-bio::after {
    content: '';
    position: absolute;
    inset: auto 0 0 0;
    height: 3em;
    background: linear-gradient(to bottom, transparent, var(--bg-dark));
    pointer-events: none;
}

.about-photo-frame {
    position: relative;
    max-width: 430px;
    margin: 0 auto;
    padding: 26px;
}

.about-photo-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #adb5bd, #4a4a4a, #2a2a2a, #adb5bd);
    animation: spin-slow 9s linear infinite;
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 calc(100% - 4px));
    mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 calc(100% - 4px));
    filter: drop-shadow(0 0 14px rgba(169, 169, 169, 0.35));
}

.about-photo-wrap {
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid rgba(255, 255, 255, 0.08);
    animation: about-float 6s ease-in-out infinite;
}

.about-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
}

.about-photo-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    box-shadow: inset 0 -40px 60px rgba(0, 0, 0, 0.45);
    pointer-events: none;
}

@keyframes spin-slow {
    to { transform: rotate(360deg); }
}

@keyframes about-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

.about-badge {
    position: absolute;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-light);
    background: rgba(18, 18, 18, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
    animation: badge-float 4.5s ease-in-out infinite;
    z-index: 2;
}

.about-badge i {
    color: #b0b5bc;
    font-size: 1rem;
}

.badge-1 { top: 6%; left: -4%; animation-delay: 0s; }
.badge-2 { top: 44%; right: -6%; animation-delay: 0.8s; }
.badge-3 { bottom: 5%; left: 8%; animation-delay: 1.6s; }

@keyframes badge-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Skills */
.skill-category-card {
    padding: 1.5rem 1.5rem 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    height: 100%;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.skill-category-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 255, 255, 0.35);
}

.skill-category-label {
    font-size: 0.95rem;
}

.skill-category-label::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: linear-gradient(120deg, #9a9a9a, #d5d5d5);
    margin-right: 0.7rem;
    box-shadow: 0 0 12px rgba(169, 169, 169, 0.4);
}

.skill-progress {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    height: 6px;
}

.skill-bar {
    background: linear-gradient(90deg, #4a4a4a, #b5b5b5);
    border-radius: 50px;
    width: 0;
    transition: width 1.2s cubic-bezier(0.25, 0.8, 0.3, 1);
}

/* Timeline */
.about-timeline {
    position: relative;
    max-width: 860px;
    margin: 0 auto;
}

.about-timeline::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 19px;
    width: 2px;
    background: linear-gradient(to bottom, rgba(169, 169, 169, 0.7), rgba(169, 169, 169, 0.05));
}

.about-timeline-item {
    position: relative;
    padding-left: 60px;
    margin-bottom: 2.5rem;
}

.about-timeline-dot {
    position: absolute;
    left: 10px;
    top: 8px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(120deg, #9a9a9a, #d5d5d5);
    box-shadow: 0 0 0 4px rgba(169, 169, 169, 0.2), 0 0 16px rgba(169, 169, 169, 0.45);
}

.about-timeline-card {
    padding: 1.5rem 1.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.about-timeline-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}

.about-timeline-date {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    color: #c8c8c8;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.22);
    padding: 0.3rem 0.8rem;
    border-radius: 50px;
    white-space: nowrap;
}

.about-achievements li {
    display: flex;
    align-items: baseline;
    color: #d7dade;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .about-timeline::before {
        left: 50%;
        margin-left: -1px;
    }

    .about-timeline-item {
        width: 50%;
        padding-left: 0;
        padding-right: 44px;
        left: 0;
    }

    .about-timeline-item:nth-child(even) {
        left: 50%;
        padding-right: 0;
        padding-left: 44px;
    }

    .about-timeline-dot {
        left: auto;
        right: -33px;
    }

    .about-timeline-item:nth-child(even) .about-timeline-dot {
        right: auto;
        left: -33px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .about-photo-ring,
    .about-photo-wrap,
    .about-badge {
        animation: none;
    }
}

/* ============================================
   Home Page
   ============================================ */

/* Floating tech background */
.hero-tech {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    transition: transform 0.3s ease-out;
}

.tech-float {
    position: absolute;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--size, 36px);
    height: var(--size, 36px);
    color: rgba(178, 184, 192, 0.34);
    filter: drop-shadow(0 0 10px rgba(169, 169, 169, 0.22));
    animation: tech-float var(--dur, 9s) ease-in-out var(--delay, 0s) infinite;
}

.tech-float i {
    font-size: var(--size, 36px);
    line-height: 1;
}

.tech-float-label {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    padding: 0.28rem 0.65rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    white-space: nowrap;
    color: #e8eaed;
    background: rgba(18, 18, 18, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 6px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    z-index: 2;
}

@media (hover: hover) {
    .tech-float:hover .tech-float-label {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes tech-float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
        opacity: 0.7;
    }
    25% {
        transform: translate(calc(var(--drift, 18px) * 0.6), -14px) rotate(var(--rot, 6deg)) scale(1.05);
    }
    50% {
        transform: translate(var(--drift, 18px), -26px) rotate(calc(var(--rot, 6deg) * -1)) scale(0.97);
        opacity: 1;
    }
    75% {
        transform: translate(calc(var(--drift, 18px) * 0.3), -8px) rotate(var(--rot, 6deg)) scale(1.02);
    }
}

/* Hero content */
.hero-greeting {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-size: 0.85rem;
    color: #b9bec7;
    margin-bottom: 0.75rem;
}

.hero-greeting::before {
    content: '';
    width: 36px;
    height: 2px;
    background: var(--primary-color);
}

.hero-name {
    line-height: 1.08;
    background: linear-gradient(120deg, #f5f5f5 20%, #9a9a9a 60%, #f5f5f5 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.hero-role {
    font-weight: 600;
    color: #e8eaed;
}

.typewriter-caret {
    display: inline-block;
    width: 3px;
    height: 0.95em;
    margin-left: 4px;
    vertical-align: -0.12em;
    background: var(--primary-color);
    animation: caret-blink 0.95s steps(1) infinite;
}

@keyframes caret-blink {
    50% { opacity: 0; }
}

.hero-photo-frame {
    max-width: 400px;
}

.hero-social {
    margin-top: 0.5rem;
}

.hero-scroll {
    position: absolute;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    color: rgba(248, 249, 250, 0.55);
    text-decoration: none;
    z-index: 1;
}

.hero-scroll:hover {
    color: rgba(248, 249, 250, 0.85);
}

.hero-scroll-text {
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.hero-scroll-icon {
    font-size: 1.1rem;
    animation: scroll-bounce 2s ease-in-out infinite;
}

@keyframes scroll-bounce {
    0%, 100% { transform: translateY(0); opacity: 0.55; }
    50% { transform: translateY(8px); opacity: 1; }
}

/* Hero entrance */
#hero .hero-greeting { animation: fadeInUp 0.7s ease-out both; }
#hero .hero-name { animation: fadeInUp 0.7s ease-out 0.12s both; }
#hero .hero-role { animation: fadeInUp 0.7s ease-out 0.24s both; }
#hero .lead { animation: fadeInUp 0.7s ease-out 0.36s both; }
#hero .hero-cta, #hero .hero-social { animation: fadeInUp 0.7s ease-out 0.48s both; }
#hero .about-photo-frame { animation: fadeInUp 1s ease-out 0.3s both; }

@media (prefers-reduced-motion: reduce) {
    .tech-float,
    .hero-scroll-icon,
    .typewriter-caret {
        animation: none;
    }
    #hero .hero-greeting,
    #hero .hero-name,
    #hero .hero-role,
    #hero .lead,
    #hero .hero-cta,
    #hero .hero-social,
    #hero .about-photo-frame {
        animation: none;
    }
}

@media (max-width: 991.98px) {
    .hero-tech {
        display: none;
    }
}

/* Home sections */
.home-section {
    padding: 4.5rem 0;
}

.home-section + .home-section {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section-head {
    max-width: 720px;
    margin: 0 auto 3rem;
    text-align: center;
}

.section-head .about-eyebrow {
    justify-content: center;
    margin-bottom: 1.1rem;
}

.section-head p {
    color: #9aa0a8;
}

/* Stats */
.stat-item {
    padding: 2rem 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    height: 100%;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 255, 255, 0.35);
}

.stat-value {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1.1;
    background: linear-gradient(120deg, #f5f5f5, #9a9a9a);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.stat-label {
    display: block;
    margin-top: 0.35rem;
    color: #9aa0a8;
    font-size: 0.9rem;
    letter-spacing: 0.04em;
}

/* Facets */
.facet-card {
    padding: 2rem 1.75rem;
    height: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.facet-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
}

.facet-icon {
    width: 58px;
    height: 58px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #e6e8ea;
    background: linear-gradient(140deg, #565656, #333333);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    margin-bottom: 1.15rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.facet-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
}

.facet-card p {
    color: #9aa0a8;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* Stack */
.stack-group {
    margin-bottom: 2.25rem;
}

.stack-group:last-child {
    margin-bottom: 0;
}

.stack-group-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #c3c7cd;
    margin-bottom: 1rem;
}

.stack-group-title::before {
    content: '';
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(120deg, #9a9a9a, #d5d5d5);
    box-shadow: 0 0 10px rgba(169, 169, 169, 0.45);
}

.tech-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 1.05rem;
    font-size: 0.92rem;
    color: #dfe2e6;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50px;
    transition: transform 0.3s ease, border-color 0.3s ease, background 0.3s ease;
}

.tech-pill:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(255, 255, 255, 0.35);
}

.tech-pill i {
    color: #b0b5bc;
    font-size: 1.05rem;
}

.tech-pill-mono {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.5rem;
    height: 1.5rem;
    padding: 0 0.32rem;
    font-size: 0.66rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: #e0e0e0;
    background: #3a3a3a;
    border-radius: 8px;
}

/* CTA */
.cta-panel {
    position: relative;
    overflow: hidden;
    padding: 3.5rem 2rem;
    text-align: center;
    background: linear-gradient(140deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.cta-panel::before {
    content: '';
    position: absolute;
    top: -60%;
    left: -15%;
    width: 75%;
    height: 220%;
    background: radial-gradient(closest-side, rgba(169, 169, 169, 0.12), transparent);
    pointer-events: none;
}

.cta-panel > * {
    position: relative;
    z-index: 1;
}

.cta-panel p {
    color: #9aa0a8;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

/* ============================================
   Projects Page
   ============================================ */

/* Filters */
.projects-filters .filter-btn {
    min-width: 0;
    padding: 0.55rem 1.35rem;
    font-weight: 500;
    color: #cfd3da;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50px;
}

.projects-filters .filter-btn:hover {
    transform: translateY(-2px);
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.35);
}

.projects-filters .filter-btn.active {
    color: #fff;
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.projects-sort .btn-group {
    gap: 0.6rem;
}

.projects-sort .btn-group > .btn {
    border-radius: 50px !important;
    margin-left: 0;
}

.projects-sort .btn {
    padding: 0.55rem 1.35rem;
    font-weight: 500;
    color: #cfd3da;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.18);
    transition: color 0.3s ease, background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.projects-sort .btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
}

.projects-sort .btn-check:checked + .btn {
    color: #fff;
    background: var(--primary-color);
    border-color: var(--primary-color);
}

/* Project cards */
.project-card .card {
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    overflow: hidden;
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.project-card:hover .project-card-inner {
    transform: translateY(-8px);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
    border-color: rgba(255, 255, 255, 0.3);
}

.project-thumb {
    border-bottom: 0;
}

.project-thumb img {
    border-bottom: 0;
    transition: transform 0.5s ease;
}

.project-card:hover .project-thumb img {
    transform: scale(1.06);
}

.pill-category {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.85rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #cfd3da;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50px;
}

.project-card .card-body {
    padding: 1.4rem 1.4rem 0.75rem;
}

.project-card .card-title {
    color: #e8eaed;
}

.project-card .card-text {
    color: #9aa0a8;
    line-height: 1.6;
}

.project-card .card-footer {
    padding: 0.75rem 1.4rem 1.4rem;
    background: transparent;
    border-top: 0;
}

.tech-pill-sm {
    padding: 0.3rem 0.72rem;
    font-size: 0.78rem;
}

.tech-pill-sm i {
    font-size: 0.85rem;
}

.tech-pill-sm .tech-pill-mono {
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.24rem;
    font-size: 0.56rem;
}

.project-details-btn {
    padding: 0.6rem 1.15rem;
    font-weight: 600;
    color: #e8eaed;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50px;
    transition: color 0.3s ease, background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.project-details-btn:hover {
    color: #fff;
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Modal */
#projectModal .modal-content {
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    overflow: hidden;
}

#projectModal .modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

#project-modal-title {
    color: #e8eaed;
}

#project-modal-tech .tech-pill {
    padding: 0.4rem 0.9rem;
    font-size: 0.85rem;
}

#projectModal pre {
    background: #0a0a0a !important;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

#projectModal .modal-body {
    padding: 1.75rem;
}

@media (prefers-reduced-motion: reduce) {
    .project-card:hover .project-card-inner,
    .project-card:hover .project-thumb img {
        transform: none;
    }
}

/* ============================================
   Resume Page
   ============================================ */

.resume-profile {
    padding: 2.25rem 2rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
}

.resume-photo {
    max-width: 220px;
    padding: 18px;
}

.contact-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 1rem;
    font-size: 0.9rem;
    color: #cfd3da;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 50px;
    text-decoration: none;
    transition: color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.contact-chip:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
}

.contact-chip i {
    color: #b0b5bc;
}

.resume-section-title {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1.75rem;
}

.resume-section-title::after {
    content: '';
    flex: 1 1 auto;
    height: 1px;
    margin-left: 0.75rem;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.22), transparent);
}

.resume-section-icon {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    color: #e6e8ea;
    background: linear-gradient(140deg, #565656, #333333);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.resume-section-title h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: #fff;
}

/* Resume stays single-column even on desktop */
.resume-timeline.about-timeline::before {
    left: 19px;
}

@media (min-width: 768px) {
    .resume-timeline.about-timeline::before {
        left: 19px;
        margin-left: 0;
    }

    .resume-timeline .about-timeline-item,
    .resume-timeline .about-timeline-item:nth-child(even) {
        width: auto;
        left: 0;
        padding-left: 60px;
        padding-right: 0;
    }

    .resume-timeline .about-timeline-dot,
    .resume-timeline .about-timeline-item:nth-child(even) .about-timeline-dot {
        left: 10px;
        right: auto;
    }
}

.resume-subtitle {
    color: #e8eaed;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.resume-subtitle i {
    color: #b0b5bc;
}

.recruiter-panel {
    padding: 2.25rem;
    background: linear-gradient(140deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border: 1px dashed rgba(255, 255, 255, 0.25);
    border-radius: 20px;
}

.availability-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1.15rem;
    font-weight: 600;
    color: #e8eaed;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
}

.language-card {
    padding: 1.5rem 1.5rem 1.25rem;
    height: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.language-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.3);
}

.reference-card {
    padding: 1.5rem;
    height: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.reference-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}

.reference-avatar {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #d5d5d5;
    background: linear-gradient(140deg, #565656, #333333);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;
}

@media (prefers-reduced-motion: reduce) {
    .resume-photo .about-photo-ring,
    .resume-photo .about-photo-wrap {
        animation: none;
    }
}