/* ==========================
   CSS RESET
========================== */

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

/* ==========================
   ROOT VARIABLES
========================== */

:root {

    --bg: #0d1117;
    --surface: #161b22;
    --border: #30363d;

    --text: #f0f6fc;
    --text-muted: #8b949e;

    --accent: #58a6ff;
    --accent-hover: #79c0ff;

    --max-width: 1100px;
}

/* ==========================
   GLOBAL
========================== */

html {
    scroll-behavior: smooth;
}

body {

    background: var(--bg);

    color: var(--text);

    font-family:
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    line-height: 1.7;
}

/* ==========================
   LINKS
========================== */

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

/* ==========================
   IMAGES
========================== */

img {
    max-width: 100%;
    display: block;
}

/* ==========================
   CONTAINER
========================== */

.container {

    width: min(92%, var(--max-width));

    margin-inline: auto;
}

/* ==========================
   NAVIGATION
========================== */

header {

    padding: 24px 0;

}

nav {

    display: flex;

    justify-content: space-between;

    align-items: center;

}

.logo {

    font-size: 1.3rem;

    font-weight: 700;

}

.nav-links {

    display: flex;

    list-style: none;

    gap: 2rem;

}

.nav-links a {

    color: var(--text-muted);

    transition: .25s;

}

.nav-links a:hover {

    color: var(--accent);

}

/* ==========================
   HERO
========================== */

#hero {

    padding: 70px 0 80px;

}

.hero-grid {
    display: block;
}

.hero-content {
    max-width: none;
}

.eyebrow {

    color: var(--accent);

    letter-spacing: 2px;

    font-size: .9rem;

    margin-bottom: 20px;

}

.hero-content h1 {

    font-size: clamp(3rem, 6vw, 5rem);

    line-height: 1.08;

    max-width: 1100px;

    letter-spacing: -2px;

}

.hero-description {

    margin-top: 32px;

    color: var(--text-muted);

    max-width: 1000px;

    font-size: 1.2rem;

    line-height: 1.8;

}

.hero-buttons {

    display: flex;

    gap: 20px;

    margin-top: 40px;

}

/* ==========================
   BUTTONS
========================== */

.btn {

    padding: 14px 26px;

    border-radius: 8px;

    border: 1px solid var(--border);

    transition: .25s;

}

.btn:hover {

    border-color: var(--accent);

}

.btn-primary {

    background: var(--accent);

    color: #000;

    border: none;

}

.btn-primary:hover {

    background: var(--accent-hover);

}

/* ==========================
   ABOUT
========================== */

#about {
    padding: 120px 0;
}

#about h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
}

.about-text {
    max-width: 1050px;
    color: var(--text-muted);
    font-size: 1.15rem;
    line-height: 1.9;
}

.stats {

    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 2rem;

    margin-top: 2.5rem;

    width: 100%;

    max-width: none;

}

.stat {

    background: var(--surface);

    border: 1px solid var(--border);

    border-radius: 12px;

    padding: 1.75rem;

    min-height: 170px;

    display: flex;

    flex-direction: column;

    justify-content: center;

    width: 100%;

}

.stat h3 {

    color: var(--accent);

    font-size: 1.9rem;

    line-height: 1.2;

    margin-bottom: .75rem;

}

.stat p {

    color: var(--text-muted);

    line-height: 1.6;

}

.stats-title {

    margin-top: 3.5rem;
    margin-bottom: 1.5rem;

    color: var(--text);

    font-size: 1.1rem;

    font-weight: 600;

    letter-spacing: .5px;

}

/* ==========================
   PROJECTS
========================== */

#projects {

    padding: 120px 0;

}

#projects h2 {

    font-size: 2rem;

    margin-bottom: 1rem;

}

.section-intro {

    color: var(--text-muted);

    line-height: 1.8;

    margin-bottom: 3rem;

}

.project-grid {

  display: grid;

  gap: 2rem;

}

/* ==========================
   PROJECT CARD
========================== */

.project-card + .project-card {
  margin-top: -80px;
}

.project-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2.5rem;
}

.project-card:nth-child(1) { z-index: 5; }
.project-card:nth-child(2) { z-index: 4; }
.project-card:nth-child(3) { z-index: 3; }
.project-card:nth-child(4) { z-index: 2; }
.project-card:nth-child(5) { z-index: 1; }

.project-card:hover {

    border-color: var(--accent);

    transform: translateY(-3px);

}

.project-header {

    display: flex;

    justify-content: space-between;

    align-items: center;

    margin-bottom: 2rem;

    gap: 1rem;

}

.project-header h3 {

    font-size: 1.5rem;

}


.project-description {

    color: var(--text-muted);

    line-height: 1.8;

    max-width: 900px;

}

.project-tags {

    display: flex;

    flex-wrap: wrap;

    gap: .75rem;

    margin: 2.5rem 0;

}


.project-highlights {

    display: grid;

    grid-template-columns:repeat(3,1fr);

    gap: 2rem;

    margin: 1.75rem 0;

    border-top: 1px solid var(--border);

    padding-top: 1.5rem;

}

.project-navigation{
    display:flex;
    align-items:center;
    gap:2rem;
    margin-bottom:2rem;
}

.project-tabs{
    flex:1;
    display:flex;
    justify-content:center;
    gap:1.5rem;
    flex-wrap:wrap;
}

.project-tab{
    background:none;
    border:none;
    color:var(--text-muted);
    font-size:.95rem;
    font-weight:500;
    padding:.5rem 0;
    cursor:pointer;
    border-bottom:2px solid transparent;
    transition:.2s;
}

.project-tab:hover{
    color:var(--text);
}

.project-tab.active{
    color:var(--accent);
    border-color:var(--accent);
    font-weight:600;
}

.project-nav-btn{
    width:42px;
    height:42px;
    border-radius:8px;
    border:1px solid var(--border);
    background:none;
    color:var(--text);
    cursor:pointer;
    transition:.2s;
}

.project-nav-btn:hover{
    border-color:var(--accent);
    color:var(--accent);
}

.project-nav-btn:disabled{
    opacity:.35;
    cursor:default;
}

#project-counter {

    color: var(--text-muted);

    font-size: .9rem;

}

.highlight {

    display: flex;

    flex-direction: column;

    gap:.25rem;

}

.highlight h4 {

    color: var(--accent);

    font-size: 2rem;

    line-height: 1;

    margin-bottom:.45rem;

}

.highlight span {

    color: var(--text-muted);

    font-size: .92rem;

    max-width: 180px;

    line-height: 1.5;

    opacity: .85;

}


.project-meta {

    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 3rem;

    margin: 2rem 0;

}

.project-meta div {

    display: flex;

    flex-direction: column;

}

.project-meta-item span:first-child {
    font-size: 0.72rem;
    
    text-transform: uppercase;
    
    letter-spacing: .14em;
    
    color: var(--text-muted);
    
    font-weight: 600;
}

.project-meta-item span:last-child {
    font-size: 1.15rem;
    
    font-weight: 600;
    
    color: var(--text);
    
    margin-top: .45rem;
}

.highlight span {
    font-size: .88rem;
    
    color: var(--text-muted);
}

.tag {
    padding: .5rem 1rem;
    
    font-size: .84rem;

    border: 1px solid var(--border);
    
    border-radius: 999px;
}

#experience {
    padding: 70px 0;

    scroll-margin-top: 120px;
}

.timeline {
    position: relative;
    margin-top: 4rem;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 130px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 1.25rem;
    position: relative;
    margin-bottom: 4rem;
}

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

.timeline-period {
    color: var(--accent);
    font-weight: 600;
    text-align: right;
    padding-top: 6px;
}

.timeline-content {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 2rem;
    max-width: 1050px;
}

.timeline-content::before {
    content: "";

    position: absolute;

    left: -30px;
    top: 33px;

    width: 19px;
    height: 2px;

    background: var(--border);
}

.timeline-content h3 {
    margin-bottom: .35rem;
}

.timeline-content h4 {
    color: var(--accent);
    margin-bottom: 1rem;
    font-weight: 500;
}

.timeline-content p {
    color: var(--text-muted);
    line-height: 1.8;
}

.timeline-title {
    display: flex;
    align-items: baseline;
    gap: .75rem;
    margin-bottom: .35rem;
}

.timeline-period{
    display:flex;
    flex-direction:column;
    align-items:flex-end;
    gap:4px;        /* try 2–4px */
    font-weight:600;
}

.current-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;

    background: rgba(78, 140, 255, 0.12);
    border: 1px solid rgba(78, 140, 255, 0.25);

    color: var(--accent);
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: .3px;
}

#skills {
    padding: 90px 0;
}

#skills h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.skills-intro {
    max-width: 900px;
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 3rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    column-gap: 2rem;
    row-gap: 2.75rem;
}

@media (max-width: 900px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }
}

.skill-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 2rem;
    transition: .25s;
    display: flex;
    flex-direction: column;
}

.skill-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(79, 140, 255, .08); 
}

.skill-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.skill-header h3 {
    font-size: 1.3rem;
}

.skill-header span {
    color: var(--accent);
    font-size: .9rem;
    font-weight: 600;
}

.skill-description {
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 1.75rem;
    flex: 1;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    margin-top: 1.5rem;
}

#contact {
    padding: 120px 0;
}

#contact h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.contact-intro {
    max-width: 760px;
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 3rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

@media (max-width:900px){

    .contact-grid{
        grid-template-columns:1fr;
    }

}

.contact-item {

    display: block;
    text-decoration: none;
    color: inherit;

    background: var(--card-bg);
    border:1px solid var(--border);
    border-radius:16px;
    padding:1.5rem;

    transition: .25s;

    cursor: pointer;

}

.contact-item:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.contact-item p {
    margin: 0;
}

.contact-label{

    display:block;
    color:var(--accent);
    font-size:.8rem;
    text-transform:uppercase;
    letter-spacing:.08em;
    margin-bottom:.75rem;

}

.contact-item a{

    color:var(--text);
    text-decoration:none;
    font-weight: 500;
}

.contact-item a:hover{

    color:var(--accent);

}

footer {
    padding: 2rem 0;
    border-top: 1px solid var(--border);
    margin-top: 4rem;
}

footer p {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}
