:root {
  --bg: #0b0f1a;
  --card: #111827;
  --text: #f8fafc;
  --muted: #9ca3af;
  --accent: #ffe159;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: radial-gradient(1200px 600px at 20% -10%, rgba(255,225,89,0.08), transparent), var(--bg);
  color: var(--text);
  line-height: 1.6;
  opacity: 0;
  animation: pageLoad 0.5s ease-out forwards;
}

@keyframes pageLoad {
  to {
    opacity: 1;
  }
}

/* subtle motion */
@media (prefers-reduced-motion: no-preference) {
  .fade-in {
    opacity: 0;
    transform: translateY(8px);
    animation: fadeIn 0.8s ease-out forwards;
  }
  .delay-1 { animation-delay: 0.1s; }
  .delay-2 { animation-delay: 0.2s; }
  .delay-3 { animation-delay: 0.3s; }
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

header {
  padding: 4.5rem 1.5rem 3rem;
  max-width: 1200px;
  margin: 0 auto;
}

.header-content {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 2rem;
  position: relative;
}

.header-left {
  flex: 0 1 900px;
  text-align: center;
}

.header-right {
  position: absolute;
  right: 0;
  top: 0.5rem;
}

.email-contact {
  color: var(--accent);
  text-decoration: none;
  font-size: 0.95rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--accent);
  border-radius: 4px;
  transition: all 0.2s;
  white-space: nowrap;
}

.email-contact:hover {
  background: var(--accent);
  color: var(--bg);
}

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    align-items: center;
  }

  .header-right {
    position: static;
    order: -1;
    margin-bottom: 1rem;
  }
}

header h1 {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  margin-bottom: 0.5rem;
}

header h2 {
  font-weight: 500;
  color: var(--accent);
  margin: 0 0 1.5rem;
  font-size: 1.2rem;
}

header p {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 720px;
  margin: 0 auto 2.5rem;
}

.cta {
  display: inline-block;
  padding: 0.75rem 1.6rem;
  border-radius: 999px;
  background: var(--accent);
  color: #020617;
  text-decoration: none;
  font-weight: 700;
}

section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 1.5rem;
}

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

.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.03), transparent), var(--card);
  border-radius: 1.25rem;
  padding: 1.8rem;
  box-shadow: 0 20px 40px rgba(0,0,0,0.35);
}

.card h3 {
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: var(--accent);
}

ul {
  padding-left: 1.2rem;
  margin: 0.5rem 0 0;
}

li {
  margin-bottom: 0.5rem;
}

.socials a {
  color: var(--muted);
  margin: 0 0.6rem;
  text-decoration: none;
  font-weight: 500;
}

.socials a:hover {
  color: var(--accent);
}

/* Projects Section */
.section-title {
  text-align: center;
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 2.5rem;
}

/* Experience Section */
.experience-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.03), transparent), var(--card);
  border-radius: 1.25rem;
  padding: 2rem;
  box-shadow: 0 20px 40px rgba(0,0,0,0.35);
  margin-bottom: 2rem;
}

.experience-card h3 {
  margin: 0 0 0.5rem;
  color: var(--accent);
  font-size: 1.5rem;
}

.projects-grid {
  display: block;
}

.project-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.03), transparent), var(--card);
  border-radius: 1.25rem;
  padding: 2rem;
  box-shadow: 0 20px 40px rgba(0,0,0,0.35);
  margin-bottom: 2rem;
}

.project-card h3 {
  margin: 0 0 0.5rem;
  color: var(--accent);
  font-size: 1.5rem;
}

.project-meta {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0 0 1rem;
  font-weight: 500;
}

.project-section-title {
  color: var(--text);
  font-size: 1rem;
  margin: 1.5rem 0 0.75rem;
  font-weight: 600;
}

.project-card h3 + .project-meta + .project-section-title {
  margin-top: 1rem;
}

.project-list {
  padding-left: 1.2rem;
  margin: 0.5rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
}

.project-list li {
  margin-bottom: 0.6rem;
}

.project-methodology {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 225, 89, 0.15);
  color: var(--muted);
  font-size: 0.9rem;
}

.project-description {
  color: var(--muted);
  margin-bottom: 1.5rem;
  line-height: 1.6;
  font-size: 0.95rem;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech-tag {
  background: rgba(255, 225, 89, 0.1);
  color: var(--accent);
  padding: 0.35rem 0.75rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid rgba(255, 225, 89, 0.2);
}

.project-read-more {
  display: inline-block;
  margin-top: 1rem;
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: transform 0.2s ease, color 0.2s ease;
}

.project-read-more:hover {
  transform: translateX(4px);
  color: #fff;
}

/* Technology Cloud - SVG Banner */
.tech-banner {
  width: 100%;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.4) 0%, transparent 100%);
  padding: 1rem 0;
  margin-bottom: 2rem;
  overflow: hidden;
}

.tech-cloud-wrapper {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 2rem;
}

.tech-cloud-svg {
  width: 100%;
  height: auto;
  display: block;
  max-height: 250px;
}

.cloud-text {
  transition: all 0.3s ease;
  cursor: default;
}

.cloud-text:hover {
  fill: var(--accent) !important;
  filter: drop-shadow(0 0 8px rgba(255, 225, 89, 0.6));
}

@media (max-width: 768px) {
  .tech-banner {
    padding: 0.5rem 0;
  }

  .tech-cloud-wrapper {
    padding: 0 1rem;
  }

  .tech-cloud-svg {
    max-height: 150px;
  }
}

/* Section Anchors */
.section-anchor {
  color: var(--muted);
  text-decoration: none;
  margin-left: 0.5rem;
  font-weight: normal;
  opacity: 0;
  transition: opacity 0.2s ease, color 0.2s ease;
  font-size: 0.8em;
}

h2:hover .section-anchor,
h3:hover .section-anchor,
.section-anchor:focus {
  opacity: 1;
}

.section-anchor:hover {
  color: var(--accent);
}

/* Career Timeline */
.timeline-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1rem;
  position: relative;
}

.timeline-container::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 100%;
  background: linear-gradient(180deg, var(--accent), rgba(255, 225, 89, 0.2));
  top: 0;
}

.timeline-item {
  position: relative;
  margin-bottom: 3rem;
  display: flex;
  align-items: flex-start;
  gap: 2rem;
}

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

.timeline-dot {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 16px;
  background: var(--accent);
  border: 3px solid var(--bg);
  border-radius: 50%;
  z-index: 2;
  box-shadow: 0 0 0 4px rgba(255, 225, 89, 0.2);
}

.timeline-dot-start {
  background: var(--muted);
  box-shadow: 0 0 0 4px rgba(156, 163, 175, 0.2);
}

.timeline-content {
  background: var(--card);
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 225, 89, 0.1);
  width: calc(50% - 2rem);
  position: relative;
  transition: all 0.3s ease;
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-left: auto;
}

.timeline-content:hover {
  border-color: rgba(255, 225, 89, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.timeline-date {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.timeline-content h3 {
  margin: 0 0 0.5rem 0;
  color: var(--text);
  font-size: 1.2rem;
}

.timeline-company {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0 0 1rem 0;
  font-weight: 500;
}

.timeline-description {
  color: var(--muted);
  line-height: 1.6;
  margin: 0 0 1rem 0;
  font-size: 0.95rem;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.timeline-tag {
  background: rgba(255, 225, 89, 0.1);
  color: var(--accent);
  padding: 0.25rem 0.6rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 500;
  border: 1px solid rgba(255, 225, 89, 0.2);
}

@media (max-width: 768px) {
  .timeline-container::before {
    left: 20px;
  }

  .timeline-dot {
    left: 20px;
  }

  .timeline-content {
    width: calc(100% - 60px);
    margin-left: 60px !important;
  }

  .timeline-item {
    flex-direction: column;
  }
}

/* Cookie Consent Banner */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--card);
  border-top: 2px solid var(--accent);
  padding: 1rem;
  z-index: 1000;
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.cookie-consent-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.cookie-consent p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.cookie-consent a {
  color: var(--accent);
  text-decoration: underline;
}

.cookie-consent a:hover {
  color: #fff;
}

.cookie-accept-btn {
  background: var(--accent);
  color: var(--bg);
  border: none;
  padding: 0.6rem 1.5rem;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.cookie-accept-btn:hover {
  background: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 225, 89, 0.3);
}

.cookie-accept-btn:active {
  transform: translateY(0);
}

@media (max-width: 768px) {
  .cookie-consent-content {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }

  .cookie-accept-btn {
    width: 100%;
  }
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background: var(--accent);
  color: var(--bg);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 999;
  box-shadow: 0 4px 12px rgba(255, 225, 89, 0.3);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: #fff;
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(255, 225, 89, 0.4);
}

.back-to-top:active {
  transform: translateY(0);
}

/* Floating Social Links */
.floating-socials {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  z-index: 1000;
}

.social-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 225, 89, 0.1);
  border: 1px solid rgba(255, 225, 89, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: lowercase;
  transition: all 0.3s ease;
}

.social-icon:hover {
  background: rgba(255, 225, 89, 0.2);
  border-color: var(--accent);
  color: var(--accent);
  transform: scale(1.1);
}

/* Hide on small screens */
@media (max-width: 768px) {
  .floating-socials {
    display: none;
  }

  .back-to-top {
    bottom: 1rem;
    right: 1rem;
    width: 45px;
    height: 45px;
  }
}

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