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

:root {
  --bg-main: #050507;
  --bg-card: #151518;
  --bg-pill: #1f1f23;
  --bg-highlight: #facc15;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --accent: #facc15;
  --accent-soft: rgba(250, 204, 21, 0.12);
  --border-subtle: #27272f;

  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-pill: 999px;

  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.55);

  --font-body: "Poppins", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
}

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

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

/* ================== LAYOUT ================== */

.page {
  min-height: 100vh;
  display: flex;
  align-items: stretch;
  justify-content: center;
  padding: 24px;
  gap: 24px;
}

/* SIDEBAR */
.sidebar {
  flex: 0 0 300px;
  max-width: 320px;
}

.sidebar-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px 24px 24px;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Avatar */

.avatar-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 18px;
}

.avatar-ring {
  width: 230px;
  height: 230px;
  border-radius: 50%;
  padding: 6px;
  background: radial-gradient(circle at 20% 0, #facc15, #78350f);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #111827;
}

/* Subtle hover effect on avatar ring */
.avatar-ring {
  transition: box-shadow 0.3s ease;
}

.avatar-wrapper:hover .avatar-ring {
  box-shadow: 0 28px 50px rgba(0, 0, 0, 0.85);
}

.sidebar-name {
  margin: 6px 0 4px;
  font-size: 20px;
  font-weight: 600;
  text-align: center;
}

.sidebar-title {
  margin: 0;
  padding: 6px 18px;
  border-radius: var(--radius-pill);
  background: var(--bg-pill);
  font-size: 12px;
  color: var(--text-muted);
}

/* Sidebar contact */

.sidebar-divider {
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.06);
  margin: 18px 0;
}

.sidebar-contact {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-item {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: rgba(15, 15, 20, 0.8);
}

.contact-icon {
  width: 32px;
  height: 32px;
  border-radius: 14px;
  background: var(--accent-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.contact-icon ion-icon {
  font-size: 18px;
}

.contact-body {
  display: flex;
  flex-direction: column;
}

.contact-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.contact-value {
  font-size: 13px;
  margin-top: 2px;
}

.sidebar-social {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.sidebar-social a {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 16px;
  transition: background 0.2s, color 0.2s, transform 0.1s;
}

.sidebar-social a:hover {
  background: var(--accent-soft);
  color: var(--accent);
  transform: translateY(-1px);
}

/* ================== MAIN CONTENT ================== */

.main {
  flex: 1 1 auto;
  max-width: 940px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 18px 30px 30px;
  display: flex;
  flex-direction: column;
}

/* ================== TOP NAV ================== */

.top-nav {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}

.top-nav nav {
  display: inline-flex;
  background: rgba(0, 0, 0, 0.35);
  border-radius: var(--radius-pill);
  padding: 4px;
}

.nav-link {
  font-size: 13px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  transition: background 0.2s, color 0.2s;
}

.nav-link.active,
.nav-link:hover {
  background: var(--accent-soft);
  color: var(--text-main);
}

/* ================== BOTTOM NAV ================== */

.bottom-nav {
  margin-top: 40px;
  padding: 16px 0 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.bottom-nav nav {
  display: flex;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
}

.bottom-nav .nav-link {
  font-size: 13px;
  color: var(--text-muted);
  padding: 6px 10px;
  border-radius: var(--radius-pill);
  transition: color 0.2s ease, background 0.2s ease;
}

.bottom-nav .nav-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.08);
}

/* ================== SECTIONS ================== */

.section {
  padding: 10px 0 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.section:first-of-type {
  border-top: none;
}

.section-title {
  font-size: 20px;
  font-weight: 600;
  margin: 8px 0 10px;
  position: relative;
}

.section-title::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 40px;
  height: 3px;
  border-radius: 999px;
  background: var(--accent);
}

.section-title--sub::before {
  display: none;
}


/* Container that narrows and centers the About Me text */
.about-content {
  max-width: 800px;       /* adjust to taste: 700–900px works well */
  margin: 0 auto;         /* centers the content */
  padding: 0 2rem;        /* left/right inner padding */
}

/* Paragraph formatting */
.about-content .intro-text {
  text-align: justify;           /* justify the text */
  line-height: 1.7;              /* cleaner, more readable spacing */
  margin-bottom: 1.2rem;         /* space between paragraphs */
}


.intro-text {
  font-size: 14px;
  color: var(--text-muted);
  max-width: 760px;
}

/* Subsection */

.subsection {
  margin-top: 22px;
}

.subsection-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 10px;
}

/* ================== SKILLS TABLE ================== */

.skills-table {
  width: 100%;
  border-radius: var(--radius-md);
  background: rgba(0, 0, 0, 0.2);
  overflow: hidden;
}

.skills-row {
  display: grid;
  grid-template-columns: minmax(140px, 220px) 1fr;
  column-gap: 18px;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.skills-row:last-child {
  border-bottom: none;
}

.skills-label {
  font-size: 13px;
  font-weight: 600;
}

.skills-value {
  font-size: 13px;
  color: var(--text-muted);
}

/* ================== PORTFOLIO GRID ================== */

.projects-grid {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

.project-card {
  background: rgba(0, 0, 0, 0.35);
  border-radius: var(--radius-md);
  padding: 12px 12px 14px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.4);
  transition: transform 0.18s ease, box-shadow 0.18s ease,
    background 0.18s ease;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.55);
  background: rgba(0, 0, 0, 0.45);
}

.project-card--empty {
  background: transparent;
  box-shadow: none;
  pointer-events: none;
}

.project-thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 14px;
  background: #111;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}

.project-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.project-title {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 6px;
}

.project-summary {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0 0 6px;
}

.project-tags {
  font-size: 11px;
  color: var(--text-muted);
  font-style: italic;
}

/* ================== TIMELINE ================== */

.timeline {
  margin-top: 14px;
}

.timeline-item {
  position: relative;
  padding-left: 18px;
  margin-bottom: 18px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 5px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.timeline-role {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 2px;
  color: var(--accent);   /* GOLD TEXT */
}

/* Org + dates */
.timeline-meta {
  font-size: 12px;
  color: var(--text-muted);
  display: grid;
  grid-template-columns: minmax(0, 2fr) auto;
  column-gap: 12px;
  align-items: baseline;
  margin-bottom: 6px;
}

.timeline-dates {
  text-align: right;
  white-space: nowrap;
}

.timeline-points {
  margin: 0;
  padding-left: 14px;
  font-size: 13px;
  color: var(--text-muted);
}

.timeline-points li + li {
  margin-top: 4px;
}

.timeline-text {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

/* ================== CONTACT FORM ================== */

.contact-form {
  margin-top: 16px;
  max-width: 640px;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.form-input {
  flex: 1 1 220px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(0, 0, 0, 0.35);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 13px;
}

.form-input::placeholder {
  color: #6b7280;
}

.form-textarea {
  margin-top: 10px;
  width: 100%;
  resize: vertical;
  min-height: 120px;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent-soft);
}

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

.btn-primary {
  margin-top: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  border: none;
  background: var(--accent);
  color: #111827;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(250, 204, 21, 0.4);
  transition: transform 0.1s ease, box-shadow 0.1s ease,
    background 0.1s ease;
}

.btn-primary ion-icon {
  font-size: 16px;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(250, 204, 21, 0.55);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 8px 20px rgba(250, 204, 21, 0.4);
}

/* ================== RESPONSIVE ================== */

@media (max-width: 1024px) {
  .page {
    flex-direction: column;
    align-items: stretch;
  }

  .sidebar,
  .main {
    max-width: 100%;
  }

  .sidebar {
    flex: 0 0 auto;
  }

  .main {
    padding: 18px 18px 24px;
  }
}

/* ================================================
   📱 MOBILE FIX (YOUR NAV BAR SCROLLBAR SOLUTION)
   ================================================ */

@media (max-width: 640px) {
  .page {
    padding: 14px;
  }

  .skills-row {
    grid-template-columns: 1fr;
    row-gap: 4px;
  }

  /* ⭐ FIXED: Nav now wraps and centers on mobile */
  .top-nav {
    justify-content: center;
  }

  .top-nav nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    width: 100%;
    overflow-x: visible;
  }

  /* stack timeline columns */
  .timeline-meta {
    grid-template-columns: 1fr;
    row-gap: 2px;
  }

  .timeline-dates {
    text-align: left;
    white-space: normal;
  }
}

/* ================== EDUCATION ================== */

.edu-timeline {
  position: relative;
  margin-top: 16px;
  margin-left: 16px;
}

.edu-timeline::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: rgba(250, 204, 21, 0.28);
  border-radius: 2px;
}

#education .timeline-item {
  display: grid;
  grid-template-columns: 40px 1fr;
  column-gap: 12px;
  align-items: flex-start;
  position: relative;
  margin-bottom: 18px;
  padding-left: 0;
}

#education .timeline-item::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 10px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.edu-logo {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.edu-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.timeline-degree {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 4px;
}

.edu-line {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

/* ================== EXPERIENCE ================== */

#experience .timeline {
  margin-left: 0;
  position: static;
}

#experience .timeline::before,
#experience .timeline-item::before {
  content: none;
}

#experience .timeline-item {
  background: rgba(0, 0, 0, 0.55);
  border-radius: 20px;
  padding: 14px 18px 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55);
  margin-bottom: 18px;
}

/* Whole card becomes 2-row, 2-column grid via areas */
#experience .exp-card {
  display: grid;
  grid-template-columns: minmax(0, 3fr) auto;
  grid-template-areas:
    "header right"
    "body   right";
  column-gap: 24px;
  align-items: flex-start;
}

/* Header: role + org (top-left) */
#experience .exp-header {
  grid-area: header;
  min-width: 0;
}

/* Body: bullets (bottom-left) */
#experience .exp-body {
  grid-area: body;
  min-width: 0;
}

/* Right column: dates + location */
#experience .exp-right {
  grid-area: right;
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
  white-space: nowrap;
}

#experience .timeline-role {
  margin: 0 0 2px;
}

#experience .exp-org {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 6px;
  font-style: italic;
}

#experience .exp-points {
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
  color: var(--text-muted);
}

#experience .exp-points li + li {
  margin-top: 4px;
}

#experience .exp-right {
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
  white-space: nowrap;
}

#experience .exp-right .exp-dates,
#experience .exp-right .exp-location {
  display: block;
}

#experience .exp-dates {
  font-style: italic;
}

/* Mobile stacking */
@media (max-width: 640px) {
  #experience .exp-card {
    grid-template-columns: 1fr;
    grid-template-areas:
      "header"
      "right"
      "body";
    row-gap: 4px;
  }

  #experience .exp-right {
    text-align: left;
    white-space: normal;
  }
}


/* ================== SIDEBAR DOWNLOAD BUTTONS ================== */

.sidebar-actions {
  width: 100%;
  margin-top: 14px;
  margin-bottom: 8px;
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: #111827;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(250, 204, 21, 0.4);
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.1s ease;
}

.btn-download ion-icon {
  font-size: 16px;
}

.btn-download:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(250, 204, 21, 0.55);
}

.btn-download:active {
  transform: translateY(0);
  box-shadow: 0 8px 20px rgba(250, 204, 21, 0.4);
}

@media (max-width: 480px) {
  .sidebar-actions {
    flex-direction: column;
  }

  .btn-download {
    width: 100%;
  }
}

/* ================== PROJECT DETAIL PAGES ================== */

.project-hero-image {
  background: rgba(0, 0, 0, 0.45);
  border-radius: var(--radius-md);
  padding: 10px;
  margin: 10px 0 18px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55);
}

.project-hero-image img {
  width: 100%;
  display: block;
  border-radius: 18px;
}

.project-meta-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.project-pill {
  font-size: 11px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--bg-pill);
  color: var(--text-muted);
}

.project-quick-facts {
  background: rgba(0, 0, 0, 0.45);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 22px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.4);
  font-size: 13px;
}

.project-quick-facts h3 {
  font-size: 14px;
  margin: 0 0 6px;
}

.project-quick-facts dl {
  margin: 0;
}

.project-quick-facts dt {
  font-weight: 600;
  margin-top: 6px;
}

.project-quick-facts dd {
  margin: 0;
  color: var(--text-muted);
}

.project-section-text {
  font-size: 14px;
  color: var(--text-muted);
}

.project-section-text p + p {
  margin-top: 8px;
}

.project-figure {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.35);
  font-size: 12px;
  color: var(--text-muted);
  font-style: italic;
}

.project-figure img {
  width: 100%;
  display: block;
  border-radius: 14px;
}



@media (max-width: 768px) {
  .project-layout {
    grid-template-columns: 1fr;
  }
}
