/* Modern Dark Portfolio Theme with Orange Accent */

/* ====================================
   1) Design Tokens (Colors, Shadows, Radii, Animations)
   ==================================== */
:root {
  /* Brand */
  --primary: #ff6a00;      /* bright orange accent */
  --primary-600: #ff7a1a;  /* hover on light surfaces */
  --primary-700: #e75f00;  /* hover on dark */

  /* Neutrals (dark theme) */
  --bg:       #0b0e14;     /* main background */
  --bg-elev:  #121620;     /* elevated surfaces */
  --surface:  #161b26;     /* cards/panels */
  --line:     #232a36;     /* lines/borders */
  --muted:    #8a93a5;     /* secondary text */
  --text:     #e8eef9;     /* main text */

  /* Feedback */
  --success:  #1fbe74;
  --warning:  #f0b429;
  --danger:   #ff4d4f;

  /* Radii/Shadows/Animations */
  --radius-xl: 1.25rem;    /* 20px */
  --radius-lg: .875rem;
  --radius-md: .625rem;

  --shadow-soft: 0 8px 24px rgba(0,0,0,.35);
  --shadow-strong: 0 12px 40px rgba(0,0,0,.5);

  --ring: 0 0 0 3px color-mix(in oklab, var(--primary) 35%, transparent);

  --ease: cubic-bezier(.2,.8,.2,1);
  --speed-fast: 150ms;
  --speed: 250ms;
}

@media (prefers-reduced-motion: reduce) {
  :root { --speed-fast: 0ms; --speed: 0ms; }
}

/* ====================================
   2) Base: Reset, Fonts, Container
   ==================================== */
* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Inter", "SF Pro Text", "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: radial-gradient(1200px 800px at 80% -10%, rgba(255,106,0,.08), transparent 60%),
              radial-gradient(900px 600px at -10% 30%, rgba(255,106,0,.06), transparent 55%),
              var(--bg);
  background-attachment: fixed;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
}

/* Container */
.container {
  width: min(1120px, 92vw);
  margin-inline: auto;
  padding-inline: 1rem;
}

/* Headings */
.h1, h1 { 
  font-size: clamp(2rem, 4.8vw, 4rem); 
  line-height: 1.1; 
  letter-spacing: -0.015em;
  font-weight: 800;
  margin: 0;
}

.h2, h2 { 
  font-size: clamp(1.5rem, 3.6vw, 2.25rem); 
  letter-spacing: -0.01em;
  font-weight: 700;
}

.h3, h3 { 
  font-size: clamp(1.125rem, 2vw, 1.25rem); 
  text-transform: uppercase; 
  color: var(--muted); 
  letter-spacing: .14em;
  font-weight: 600;
}

p.lead {
  font-size: clamp(1.05rem, 1.3vw, 1.25rem);
  color: color-mix(in oklab, var(--text) 85%, white 15%);
  max-width: 62ch;
  line-height: 1.7;
}

/* Background noise effect */
.bg-noise::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="140" height="140" viewBox="0 0 140 140"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.9" numOctaves="2" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23n)" opacity="0.035"/></svg>');
  pointer-events: none;
  z-index: 1;
  mix-blend-mode: overlay;
}

/* ====================================
   3) Navigation
   ==================================== */
.nav {
  position: sticky; 
  top: 0; 
  z-index: 40;
  backdrop-filter: saturate(140%) blur(10px);
  background: linear-gradient(180deg, rgba(11,14,20,.85), rgba(11,14,20,.6));
  border-bottom: 1px solid var(--line);
}

.nav__inner { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  gap: 1rem; 
  padding: .8rem 0; 
}

.controls {
  display: flex;
  gap: .75rem;
  align-items: center;
}

.language-switch, .theme-switch {
  display: flex;
  gap: .4rem;
}

.lang-btn, .theme-btn {
  display: inline-flex;
  align-items: center;
  padding: .5rem .9rem;
  border-radius: 999px;
  background: rgba(255,255,255,.03);
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 600;
  font-size: .9rem;
  cursor: pointer;
  transition: all var(--speed) var(--ease);
}

.lang-btn:hover, .theme-btn:hover {
  border-color: color-mix(in oklab, var(--primary) 40%, var(--line));
  transform: translateY(-1px);
}

.lang-btn.active, .theme-btn.active {
  background: linear-gradient(180deg, color-mix(in oklab, var(--primary) 88%, #fff 0%), color-mix(in oklab, var(--primary) 72%, #000 8%));
  border-color: color-mix(in oklab, var(--primary) 46%, #000);
  color: #0c0c0c;
  box-shadow: 0 4px 12px color-mix(in oklab, var(--primary) 28%, transparent);
}

/* ====================================
   4) Hero Section
   ==================================== */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
  padding: clamp(2rem, 5vw, 5rem) 0;
}

@media (max-width: 920px) {
  .hero { 
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero__cta {
    justify-content: center;
  }
}

.hero__title {
  font-weight: 800;
  margin: 0 0 .75rem 0;
  text-wrap: balance;
}

.hero__role {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .5rem .8rem;
  border-radius: 999px;
  background: linear-gradient(180deg, color-mix(in oklab, var(--primary) 24%, transparent), transparent 65%);
  border: 1px solid color-mix(in oklab, var(--primary) 34%, var(--line));
  color: color-mix(in oklab, var(--text) 86%, white 14%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  font-weight: 600;
  font-size: .95rem;
  margin-bottom: 1rem;
}

.hero__lead { 
  margin: 1rem 0 1.5rem; 
}

.hero__cta { 
  display: flex; 
  flex-wrap: wrap; 
  gap: .75rem; 
}

/* Profile Photo Card */
.profile {
  position: relative;
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.00));
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.profile__media {
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 6rem;
  color: rgba(255,255,255,.6);
  background: linear-gradient(135deg, var(--surface), var(--bg-elev));
}

.profile__glow {
  position: absolute; 
  inset: -30%;
  background: radial-gradient(45% 40% at 70% 20%, color-mix(in oklab, var(--primary) 18%, transparent), transparent 60%);
  filter: blur(40px);
  opacity: .9;
  pointer-events: none;
}

/* ====================================
   5) Buttons
   ==================================== */
.button {
  --btn-bg: var(--primary);
  --btn-fg: #0c0c0c;
  display: inline-flex; 
  align-items: center; 
  gap: .6rem;
  border: 1px solid color-mix(in oklab, var(--primary) 46%, #000);
  background: linear-gradient(180deg, color-mix(in oklab, var(--primary) 88%, #fff 0%), color-mix(in oklab, var(--primary) 72%, #000 8%));
  color: var(--btn-fg);
  padding: .85rem 1.1rem;
  border-radius: .9rem;
  font-weight: 700;
  letter-spacing: .01em;
  transition: transform var(--speed) var(--ease), box-shadow var(--speed) var(--ease), background var(--speed) var(--ease);
  box-shadow: 0 6px 18px color-mix(in oklab, var(--primary) 28%, transparent);
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  transform: translateY(-1px);
  background: linear-gradient(180deg, color-mix(in oklab, var(--primary) 92%, #fff 0%), color-mix(in oklab, var(--primary) 78%, #000 10%));
  box-shadow: 0 10px 26px color-mix(in oklab, var(--primary) 38%, transparent);
  color: #ffffff;
}

.button:active { 
  transform: translateY(0); 
}

.button--ghost {
  --btn-fg: var(--text);
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.00));
  border: 1px solid var(--line);
  color: var(--text);
  box-shadow: none;
}

.button--ghost:hover {
  border-color: color-mix(in oklab, var(--primary) 40%, var(--line));
  color: #ffffff;
}

/* Links */
a { 
  color: var(--primary); 
  text-decoration: none; 
}

a:hover { 
  color: var(--primary-600); 
}

/* ====================================
   6) Cards & Grid
   ==================================== */
.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(12, 1fr);
}

@media (max-width: 920px) {
  .grid { 
    grid-template-columns: repeat(6, 1fr); 
  }
}

.card {
  grid-column: span 6;
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.0));
  border: 1px solid var(--line);
  padding: 1.5rem;
  transition: border-color var(--speed) var(--ease), transform var(--speed) var(--ease);
}

.card:hover {
  border-color: color-mix(in oklab, var(--primary) 30%, var(--line));
  transform: translateY(-2px);
}

.card__title { 
  font-weight: 700; 
  margin: .25rem 0 .4rem;
  font-size: 1.15rem;
  color: var(--text);
}

.card__meta { 
  color: var(--muted); 
  font-size: .95rem;
  line-height: 1.5;
}

.card--wide { 
  grid-column: span 12; 
}

@media (max-width: 920px) {
  .card {
    grid-column: span 6;
  }
}

/* ====================================
   7) Tags / Skills
   ==================================== */
.tags { 
  display: flex; 
  flex-wrap: wrap; 
  gap: .5rem;
  margin-top: .8rem;
}

.tag {
  display: inline-flex; 
  align-items: center; 
  gap: .5rem;
  padding: .45rem .7rem;
  border-radius: 999px;
  background: rgba(255,255,255,.03);
  border: 1px solid var(--line);
  color: color-mix(in oklab, var(--text) 90%, white 10%);
  font-weight: 600; 
  font-size: .85rem;
}

.tag--hot { 
  border-color: color-mix(in oklab, var(--primary) 40%, var(--line)); 
  background: linear-gradient(180deg, rgba(255,106,0,.08), rgba(255,106,0,.03)); 
}

/* ====================================
   8) Sections
   ==================================== */
.section { 
  padding: clamp(2rem, 4vw, 3rem) 0; 
}

.section__head { 
  margin-bottom: 1.5rem; 
}

.section__head .h2 {
  margin-bottom: .5rem;
}

.section__head p {
  color: var(--muted);
  font-size: 1rem;
}

.hr {
  height: 1px; 
  background: linear-gradient(90deg, transparent, var(--line), transparent);
  margin: 2rem 0;
  border: none;
}

/* ====================================
   9) Experience & Education Items
   ==================================== */
.experience-item, .education-item {
  background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.0));
  border: 1px solid var(--line);
  border-left: 3px solid var(--primary);
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  border-radius: var(--radius-lg);
  transition: border-color var(--speed) var(--ease), transform var(--speed) var(--ease);
}

.experience-item:hover, .education-item:hover {
  border-left-color: var(--primary-600);
  transform: translateX(2px);
}

.experience-item h4, .education-item h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: .4rem;
}

.experience-item .company, .education-item .institution {
  font-weight: 600;
  color: var(--primary);
  margin-bottom: .3rem;
  font-size: 1rem;
}

.experience-item .years, .education-item .years {
  font-style: italic;
  color: var(--muted);
  font-size: .9rem;
  margin-bottom: .8rem;
}

.responsibilities {
  margin-top: 1rem;
}

.responsibilities ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.responsibilities li {
  padding: .4rem 0;
  font-size: .95rem;
  color: color-mix(in oklab, var(--text) 90%, white 10%);
  position: relative;
  padding-left: 1.2rem;
  line-height: 1.6;
}

.responsibilities li:before {
  content: "•";
  color: var(--primary);
  font-weight: bold;
  position: absolute;
  left: 0;
  font-size: 1.2rem;
}

/* ====================================
   10) Profile List
   ==================================== */
#profile-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: .8rem;
}

#profile-list li {
  background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.0));
  border: 1px solid var(--line);
  border-left: 3px solid var(--primary);
  padding: 1rem 1.2rem;
  border-radius: var(--radius-md);
  font-size: .95rem;
  line-height: 1.6;
  color: color-mix(in oklab, var(--text) 92%, white 8%);
  transition: border-color var(--speed) var(--ease), transform var(--speed) var(--ease);
}

#profile-list li:hover {
  border-left-color: var(--primary-600);
  transform: translateX(2px);
}

/* ====================================
   11) Contact Section
   ==================================== */
.contact-section {
  margin-top: 1.5rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: .8rem;
  margin-bottom: 1rem;
  font-size: .95rem;
  color: var(--text);
}

.contact-item i {
  width: 1.2rem;
  color: var(--primary);
  font-size: 1.1rem;
}

.contact-item a {
  color: var(--text);
  transition: color var(--speed) var(--ease);
}

.contact-item a:hover {
  color: var(--primary);
}

/* ====================================
   12) Skills List
   ==================================== */
.skills-section ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
}

.skills-section li {
  background: rgba(255,255,255,.03);
  border: 1px solid var(--line);
  padding: .5rem .8rem;
  border-radius: 999px;
  font-size: .85rem;
  font-weight: 600;
  color: color-mix(in oklab, var(--text) 90%, white 10%);
  transition: all var(--speed) var(--ease);
}

.skills-section li:hover {
  border-color: color-mix(in oklab, var(--primary) 40%, var(--line));
  background: linear-gradient(180deg, rgba(255,106,0,.08), rgba(255,106,0,.03));
}

/* ====================================
   13) Layout Structure
   ==================================== */
.cv-container {
  max-width: 100%;
  margin: 0;
  background: transparent;
}

.cv-wrapper {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.left-column, .right-column {
  width: 100%;
}

/* ====================================
   14) Focus States
   ==================================== */
:where(a, button, input, textarea):focus-visible {
  outline: none; 
  box-shadow: var(--ring);
  border-radius: .6rem;
}

/* ====================================
   15) Responsive Design
   ==================================== */

/* Mobile-optimized background */
@media (max-width: 768px) {
  body {
    background: radial-gradient(800px 600px at 50% 0%, rgba(255,106,0,.1), transparent 70%),
                radial-gradient(600px 500px at 50% 100%, rgba(255,106,0,.08), transparent 65%),
                var(--bg);
    background-attachment: fixed;
  }
  
  .container {
    width: 100%;
    padding-inline: 1rem;
  }
  
  .hero {
    padding: 2rem 0;
    gap: 2rem;
  }
  
  .hero__title {
    font-size: clamp(1.75rem, 8vw, 2.5rem);
  }
  
  .hero__lead {
    font-size: 1rem;
  }
  
  .hero__cta {
    flex-direction: column;
    width: 100%;
  }
  
  .hero__cta .button {
    width: 100%;
    justify-content: center;
  }
  
  .section {
    padding: 1.5rem 0;
  }
  
  .section__head .h2 {
    font-size: 1.5rem;
  }
  
  .card {
    padding: 1.2rem;
    grid-column: span 6;
  }
  
  .experience-item, .education-item {
    padding: 1.2rem;
  }
  
  .controls {
    flex-direction: row;
    gap: .5rem;
  }
  
  .language-switch {
    flex-direction: row;
  }
  
  .lang-btn {
    padding: .45rem .75rem;
    font-size: .85rem;
  }
  
  .profile__media {
    aspect-ratio: 1;
  }
  
  .nav__inner {
    padding: .6rem 0;
  }
  
  .logo .h3 {
    font-size: 1rem;
  }
}

/* Extra small devices */
@media (max-width: 480px) {
  body {
    background: radial-gradient(600px 500px at 50% 0%, rgba(255,106,0,.12), transparent 75%),
                radial-gradient(500px 400px at 50% 100%, rgba(255,106,0,.1), transparent 70%),
                var(--bg);
    background-attachment: fixed;
  }
  
  .container {
    padding-inline: .75rem;
  }
  
  .hero {
    padding: 1.5rem 0;
  }
  
  .hero__role {
    font-size: .85rem;
    padding: .4rem .7rem;
  }
  
  .hero__title {
    font-size: 1.75rem;
    margin-bottom: .5rem;
  }
  
  .button {
    padding: .75rem 1rem;
    font-size: .9rem;
  }
  
  .card {
    padding: 1rem;
  }
  
  .experience-item, .education-item {
    padding: 1rem;
  }
  
  .section__head .h2 {
    font-size: 1.35rem;
  }
  
  .section__head p {
    font-size: .9rem;
  }
  
  .lang-btn {
    padding: .4rem .65rem;
    font-size: .8rem;
  }
}

/* ====================================
   16) Footer
   ==================================== */
.footer {
  background: linear-gradient(180deg, transparent, rgba(255,255,255,.01));
  border-top: 1px solid var(--line);
  margin-top: 4rem;
  padding: 3rem 0 2rem;
}

.footer__content {
  display: grid;
  gap: 2.5rem;
}

.footer__info {
  text-align: center;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}

.footer__made-by {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 .5rem 0;
}

.footer__dates {
  font-size: .9rem;
  color: var(--muted);
  margin: 0;
}

.footer__links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.footer__section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer__section-title {
  font-size: .85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--primary);
  margin: 0;
}

.footer__link-group {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.footer__link {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .5rem .75rem;
  border-radius: .5rem;
  color: var(--text);
  text-decoration: none;
  transition: all var(--speed) var(--ease);
  background: rgba(255,255,255,.02);
  border: 1px solid transparent;
}

.footer__link:hover {
  background: rgba(255,255,255,.04);
  border-color: color-mix(in oklab, var(--primary) 30%, var(--line));
  transform: translateX(4px);
  color: var(--primary);
}

.footer__link i {
  width: 1.2rem;
  font-size: 1.1rem;
  color: var(--primary);
}

.footer__link span {
  font-size: .9rem;
  font-weight: 500;
}

@media (max-width: 768px) {
  .footer {
    padding: 2rem 0 1.5rem;
    margin-top: 2rem;
  }
  
  .footer__links {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .footer__info {
    padding-bottom: 1rem;
  }
}

@media (max-width: 480px) {
  .footer {
    padding: 1.5rem 0 1rem;
  }
  
  .footer__made-by {
    font-size: .9rem;
  }
  
  .footer__dates {
    font-size: .85rem;
  }
  
  .footer__link {
    padding: .45rem .65rem;
  }
  
  .footer__link span {
    font-size: .85rem;
  }
}