/* ===== LIGHT MODE ===== */
[data-theme="light"] {
  --bg: #f5f5f5;
  --bg-card: #ffffff;
  --bg-card-hover: #fafafa;
  --border: rgba(0,0,0,0.08);
  --text: #1a1a2e;
  --text-muted: #52525b;
  --accent: #0891b2;
  --accent2: #7c3aed;
}
[data-theme="light"] body::before {
  background-image:
    linear-gradient(rgba(0,0,0,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.03) 1px, transparent 1px);
}
[data-theme="light"] .navbar {
  background: rgba(255,255,255,0.85);
}
[data-theme="light"] .tool-input,
[data-theme="light"] .contact-form input,
[data-theme="light"] .contact-form textarea,
[data-theme="light"] .contact-form select {
  background: var(--bg);
}

/* Theme Toggle */
.theme-toggle {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent; color: var(--text);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 1.1rem; transition: all 0.3s;
  flex-shrink: 0;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }

/* ===== 3D PHOTO ANIMATION ===== */
.hero-photo { perspective: 800px; }
.hero-photo img {
  transition: transform 0.4s ease;
  transform-style: preserve-3d;
}
.hero-photo:hover img {
  transform: rotateY(8deg) rotateX(-5deg) scale(1.03);
  box-shadow: 0 0 50px rgba(0,229,255,0.25);
}

/* ===== ANIMATED SKILL ICONS ===== */
.logo-item {
  transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
  display: inline-flex; align-items: center; gap: 0.3rem;
}
.logo-item:hover {
  transform: translateY(-6px) scale(1.15) rotateZ(-3deg);
  opacity: 1 !important;
  text-shadow: 0 0 15px rgba(0,229,255,0.4);
}
.skill-card .skill-icon {
  transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
  transform-style: preserve-3d;
}
.skill-card:hover .skill-icon {
  transform: rotateY(180deg) scale(1.1);
  background: rgba(0,229,255,0.12);
  box-shadow: 0 0 20px rgba(0,229,255,0.15);
}

/* ===== ARMGHAN.ME STYLE TIMELINE (Experience & Certs) ===== */
.section-center-header { text-align: center; margin-bottom: 2.5rem; }
.section-title-center {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800; line-height: 1.2;
}
.title-underline {
  width: 50px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  margin: 0.75rem auto 0;
}

.armghan-timeline-wrap {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  border: 1px solid var(--border);
}
.armghan-tl-item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 2.5rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
  position: relative;
  align-items: flex-start;
}
.armghan-tl-item:last-child { border-bottom: none; }
.armghan-tl-item:first-child { padding-top: 0; }
.armghan-tl-item:last-child { padding-bottom: 0; }

/* Timeline dot on the left edge of content */
.armghan-tl-dot {
  position: absolute;
  left: 155px;
  top: 2.8rem;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--text-muted);
  opacity: 0.3;
}
.armghan-tl-item:first-child .armghan-tl-dot { top: 0.3rem; }

/* Big date on the left */
.armghan-tl-date {
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.2;
  letter-spacing: -0.5px;
}

/* Content on the right */
.armghan-tl-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  line-height: 1.3;
}
.armghan-tl-org {
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
}
.armghan-tl-content p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ===== RESULTS SECTION ===== */
.results-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem;
}
.result-card {
  padding: 2rem; border-radius: 14px; text-align: center;
  background: var(--bg-card); border: 1px solid var(--border);
  transition: all 0.3s;
}
.result-card:hover { border-color: var(--accent); transform: translateY(-5px); box-shadow: 0 15px 40px rgba(0,229,255,0.06); }
.result-number {
  font-size: 2.5rem; font-weight: 900;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  margin-bottom: 0.25rem;
}
.result-label { font-weight: 700; font-size: 0.95rem; margin-bottom: 0.4rem; }
.result-desc { color: var(--text-muted); font-size: 0.82rem; line-height: 1.5; }

/* ===== NEW CONTACT (armghan.me style) ===== */
.contact-header-center { text-align: center; margin-bottom: 3rem; }
.contact-header-center .section-desc { margin-left: auto; margin-right: auto; }
.contact-layout { display: grid; grid-template-columns: 1fr 1.2fr; gap: 3rem; align-items: flex-start; }
.contact-left h3 { font-size: 1.3rem; margin-bottom: 0.75rem; }
.contact-left > p { color: var(--text-muted); font-size: 0.92rem; margin-bottom: 1.5rem; line-height: 1.6; }
.contact-items { display: flex; flex-direction: column; gap: 0.75rem; }
.contact-item {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem 1.25rem; border-radius: 12px;
  background: var(--bg-card); border: 1px solid var(--border);
  transition: all 0.3s;
}
.contact-item:hover { border-color: var(--accent); transform: translateX(5px); }
.contact-item i {
  width: 42px; height: 42px; border-radius: 10px;
  background: rgba(0,229,255,0.06); color: var(--accent);
  display: flex; align-items: center; justify-content: center; font-size: 1.1rem; flex-shrink: 0;
}
.contact-item .ci-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1.5px; color: var(--accent); font-weight: 600; }
.contact-item .ci-value { font-size: 0.92rem; }

/* Resume download buttons */
.resume-section { margin-top: 2rem; }
.resume-section h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 2px; color: var(--text-muted); margin-bottom: 0.75rem; }
.resume-btns { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.resume-btns a {
  padding: 0.5rem 1rem; border-radius: 8px;
  border: 1px solid var(--border); font-size: 0.82rem;
  font-weight: 500; transition: all 0.3s; color: var(--text);
}
.resume-btns a:hover { border-color: var(--accent); color: var(--accent); background: rgba(0,229,255,0.04); }

/* Contact form (armghan style) */
.contact-right label { font-size: 0.85rem; font-weight: 600; display: block; margin-bottom: 0.4rem; }
.contact-form { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.contact-form .full-width { grid-column: 1 / -1; }
.contact-form select {
  width: 100%; padding: 0.85rem 1rem; border-radius: 10px;
  background: var(--bg-card); border: 1px solid var(--border);
  color: var(--text); font-family: var(--font); font-size: 0.9rem;
  outline: none; transition: border 0.3s; appearance: none;
  cursor: pointer;
}
.contact-form select:focus { border-color: var(--accent); }

/* ===== NEW FOOTER (armghan.me style: multi-column) ===== */
.new-footer {
  padding: 3rem 2rem 1.5rem; border-top: 1px solid var(--border);
  position: relative; z-index: 1;
}
.footer-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 2rem;
  padding-bottom: 2rem; border-bottom: 1px solid var(--border);
}
.footer-brand .fb-name { font-size: 1.2rem; font-weight: 800; margin-bottom: 0.5rem; }
.footer-brand .fb-desc { color: var(--text-muted); font-size: 0.82rem; line-height: 1.6; margin-bottom: 0.5rem; }
.footer-brand .fb-loc { color: var(--text-muted); font-size: 0.8rem; }
.footer-col h4 { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 2px; color: var(--text-muted); margin-bottom: 1rem; }
.footer-col a { display: block; color: var(--text-muted); font-size: 0.88rem; margin-bottom: 0.6rem; transition: color 0.3s; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  max-width: 1100px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 1.5rem; padding-right: 6rem; flex-wrap: wrap; gap: 1rem;
}
.footer-bottom .fb-copy { color: var(--text-muted); font-size: 0.8rem; }
.footer-bottom .scroll-top {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--border); background: transparent;
  color: var(--text-muted); display: flex; align-items: center;
  justify-content: center; cursor: pointer; transition: all 0.3s;
  position: relative; z-index: 1000;
}
.footer-bottom .scroll-top:hover { border-color: var(--accent); color: var(--accent); }

/* ===== ANIMATED TO-DO MOCKUP ===== */
.todo-mockup {
  margin-top: 1.25rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border);
  overflow: hidden;
}
.todo-mockup__header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 0.85rem;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
}
.todo-mockup__dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.todo-mockup__title {
  margin-left: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}
.todo-mockup__item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  opacity: 0;
  animation: todoFadeIn 0.5s ease forwards;
}
.todo-mockup__item:last-child { border-bottom: none; }

@keyframes todoFadeIn {
  from { opacity: 0; transform: translateX(-10px); }
  to { opacity: 1; transform: translateX(0); }
}

.todo-mockup__check {
  width: 18px; height: 18px;
  border-radius: 4px;
  background: var(--green);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.todo-mockup__check i {
  font-size: 0.55rem;
  color: #fff;
}
.todo-mockup__radio {
  width: 18px; height: 18px;
  border-radius: 4px;
  border: 2px solid rgba(255,255,255,0.15);
  flex-shrink: 0;
}
.todo-mockup__text {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.3;
}
.todo-mockup__item--done .todo-mockup__text {
  text-decoration: line-through;
  opacity: 0.5;
}
.todo-mockup__item--active .todo-mockup__text {
  color: var(--accent);
  font-weight: 500;
}
.todo-mockup__item--active .todo-mockup__radio {
  border-color: var(--accent);
  box-shadow: 0 0 6px rgba(0,229,255,0.3);
}

/* ===== MINI TIC-TAC-TOE GAME ===== */
.ttt-game {
  margin-top: 1rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border);
  overflow: hidden;
}
.ttt-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.85rem;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
}
.ttt-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.ttt-label i { color: var(--accent); }
.ttt-reset {
  width: 24px; height: 24px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.9rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.3s;
  line-height: 1;
}
.ttt-reset:hover { border-color: var(--accent); color: var(--accent); }
.ttt-status {
  text-align: center;
  font-size: 0.72rem;
  font-family: var(--mono);
  color: var(--accent);
  padding: 0.35rem;
}
.ttt-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
  padding: 0.5rem 0.85rem 0.85rem;
}
.ttt-cell {
  aspect-ratio: 1;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  background: rgba(255,255,255,0.02);
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
}
.ttt-cell:hover:not(:disabled) {
  background: rgba(0,229,255,0.06);
  border-color: rgba(0,229,255,0.2);
}
.ttt-cell:disabled { cursor: default; }
.ttt-cell.x { color: var(--accent); text-shadow: 0 0 8px rgba(0,229,255,0.4); }
.ttt-cell.o { color: var(--accent2); text-shadow: 0 0 8px rgba(168,85,247,0.4); }
.ttt-cell.win {
  background: rgba(0,229,255,0.1);
  border-color: var(--accent);
  animation: tttPulse 0.6s ease;
}
@keyframes tttPulse {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* ===== NLE TIMELINE MOCKUP ===== */
.nle-timeline {
  margin-top: 1.25rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.4);
  border: 1px solid var(--border);
  overflow: hidden;
}
.nle-header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.75rem;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
}
.nle-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.nle-title {
  margin-left: 0.4rem;
  font-size: 0.65rem;
  font-family: var(--mono);
  color: var(--text-muted);
  flex: 1;
}
.nle-timecode {
  font-size: 0.65rem;
  font-family: var(--mono);
  color: var(--accent);
  background: rgba(0,229,255,0.08);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}
.nle-ruler {
  display: flex;
  justify-content: space-between;
  padding: 0.25rem 0.75rem 0.25rem 2.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 0.55rem;
  color: var(--text-muted);
  font-family: var(--mono);
}
.nle-tracks {
  position: relative;
  padding: 0.35rem 0;
}
.nle-track {
  display: flex;
  align-items: center;
  height: 26px;
  margin-bottom: 2px;
}
.nle-track-label {
  width: 2rem;
  text-align: center;
  font-size: 0.6rem;
  font-family: var(--mono);
  color: var(--text-muted);
  flex-shrink: 0;
}
.nle-track-area {
  flex: 1;
  position: relative;
  height: 100%;
  margin-right: 0.5rem;
}
.nle-clip {
  position: absolute;
  top: 2px;
  height: calc(100% - 4px);
  border-radius: 4px;
  display: flex;
  align-items: center;
  padding: 0 0.4rem;
  font-size: 0.55rem;
  font-family: var(--mono);
  font-weight: 600;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.nle-clip--main {
  background: rgba(66,135,245,0.25);
  border: 1px solid rgba(66,135,245,0.4);
  color: #93bbfc;
}
.nle-clip--overlay {
  background: rgba(168,85,247,0.2);
  border: 1px solid rgba(168,85,247,0.35);
  color: #c9a0f7;
}
.nle-clip--title {
  background: rgba(234,179,8,0.2);
  border: 1px solid rgba(234,179,8,0.35);
  color: #eab308;
}
.nle-clip--audio {
  background: rgba(34,197,94,0.15);
  border: 1px solid rgba(34,197,94,0.3);
  color: #22c55e;
}
.nle-clip--music {
  background: rgba(239,68,68,0.15);
  border: 1px solid rgba(239,68,68,0.3);
  color: #f87171;
  font-size: 0.55rem;
}
/* Audio waveform */
.nle-waveform {
  display: flex;
  align-items: center;
  gap: 1.5px;
  height: 100%;
  overflow: hidden;
}
.nle-waveform span {
  flex-shrink: 0;
  width: 2px;
  background: rgba(34,197,94,0.5);
  border-radius: 1px;
  animation: waveAnim 1.5s ease-in-out infinite alternate;
}
.nle-waveform span:nth-child(odd) { height: 40%; animation-delay: 0s; }
.nle-waveform span:nth-child(even) { height: 70%; animation-delay: 0.2s; }
.nle-waveform span:nth-child(3n) { height: 90%; animation-delay: 0.4s; }
.nle-waveform span:nth-child(4n) { height: 55%; animation-delay: 0.6s; }
.nle-waveform span:nth-child(5n) { height: 80%; animation-delay: 0.1s; }
@keyframes waveAnim {
  0% { transform: scaleY(0.4); }
  100% { transform: scaleY(1); }
}
/* Playhead */
.nle-playhead {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--accent);
  box-shadow: 0 0 6px rgba(0,229,255,0.6);
  z-index: 5;
  left: 2.5rem;
  animation: playheadSweep 8s linear infinite;
}
.nle-playhead::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -4px;
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--accent);
}
@keyframes playheadSweep {
  0% { left: 2.5rem; }
  100% { left: calc(100% - 0.5rem); }
}

/* ===== CYBER TERMINAL MOCKUP ===== */
.cyber-terminal {
  margin-top: 1.25rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.4);
  border: 1px solid var(--border);
  overflow: hidden;
}
.cyber-terminal__header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.85rem;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
}
.cyber-terminal__body {
  padding: 0.6rem 0.85rem;
  max-height: 220px;
  overflow-y: auto;
}
.cyber-line {
  font-family: var(--mono);
  font-size: 0.68rem;
  line-height: 1.6;
  color: var(--text-muted);
  opacity: 0;
  animation: cyberFadeIn 0.4s ease forwards;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
@keyframes cyberFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}
.cyber-prompt {
  color: var(--accent);
  font-weight: 700;
  margin-right: 0.3rem;
}
.cyber-output { color: rgba(255,255,255,0.4); }
.cyber-success { color: var(--green); font-weight: 600; }
.cyber-cursor {
  animation: blink 0.7s infinite;
  color: var(--accent);
}

/* ===== MOBILE RESPONSIVE ADDITIONS ===== */
@media(max-width:968px) {
  .contact-layout { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .armghan-tl-item { grid-template-columns: 100px 1fr; gap: 1.5rem; }
  .armghan-tl-dot { left: 112px; }
  .armghan-tl-date { font-size: 1.2rem; }
  .results-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
}
@media(max-width:640px) {
  .footer-grid { grid-template-columns: 1fr; }
  .results-grid { grid-template-columns: 1fr 1fr; }
  .contact-form { grid-template-columns: 1fr; }
  .resume-btns { flex-direction: column; }
  .resume-btns a { text-align: center; }
  .armghan-tl-item { grid-template-columns: 1fr; gap: 0.5rem; }
  .armghan-tl-dot { display: none; }
  .armghan-timeline-wrap { padding: 1.5rem 1rem; }
  .contact-items { gap: 0.5rem; }
  .contact-item { padding: 0.75rem 1rem; }
  .contact-item i { width: 36px; height: 36px; font-size: 0.95rem; }
  .footer-bottom { padding-right: 0; justify-content: center; text-align: center; }
}
@media(max-width:375px) {
  .armghan-timeline-wrap { padding: 1rem 0.75rem; }
  .armghan-tl-item { padding: 1.5rem 0; }
  .armghan-tl-content h3 { font-size: 1rem; }
  .armghan-tl-content p { font-size: 0.82rem; }
  .result-card { padding: 1.5rem 1rem; }
  .result-number { font-size: 2rem; }
  .contact-left h3 { font-size: 1.15rem; }
  .footer-brand .fb-desc { font-size: 0.78rem; }
  .footer-col a { font-size: 0.82rem; }
  .results-grid { grid-template-columns: 1fr; }
}
