:root {
  --bg-main: #0f172a;
  --bg-alt: #1e293b;
  --card-bg: rgba(30, 41, 59, 0.7);
  --border-subtle: rgba(148, 163, 184, 0.1);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent: #38bdf8;
  --accent-soft: rgba(56, 189, 248, 0.15);
  --gradient-primary: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --font-main: "Inter", system-ui, -apple-system, sans-serif;
  --font-heading: "Outfit", system-ui, -apple-system, sans-serif;
}

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

html,
body {
  margin: 0;
  padding: 0;
  font-family: var(--font-main);
  background: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  letter-spacing: -0.025em;
  font-weight: 700;
  color: #fff;
}

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

img {
  max-width: 100%;
  height: auto;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: #020617;
  font-weight: 600;
  border-radius: 0.5rem;
  transition: top 0.2s ease;
  z-index: 30;
}

.skip-link:focus-visible {
  top: 1rem;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(2, 6, 23, 0.98);
  border-bottom: 1px solid var(--border-subtle);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0.5rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-size: 1.15rem;
  line-height: 1;
}

.logo-image {
  display: block;
  height: clamp(64px, 7vw, 82px);
  width: auto;
  max-width: 140px;
  padding: 10px 14px;
  border-radius: 0.85rem;
  border: 1px solid var(--border-subtle);
  background: rgba(11, 18, 32, 0.7);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.38);
}

.nav {
  display: flex;
  gap: 1.25rem;
  font-size: 0.96rem;
}

.nav a {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.1rem 0.1rem;
  line-height: 1.2;
  border-bottom: 1px solid transparent;
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--accent);
  border-color: transparent;
  /* Removed bottom border for cleaner look */
}

/* Hero */

.hero {
  padding: 8rem 0 6rem;
  background:
    radial-gradient(circle at 15% 50%, rgba(56, 189, 248, 0.08), transparent 25%),
    radial-gradient(circle at 85% 30%, rgba(14, 165, 233, 0.08), transparent 25%);
  position: relative;
  overflow: hidden;
}

.hero-inner {
  text-align: center;
  position: relative;
  z-index: 10;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 1.5rem;
  line-height: 1.1;
  background: linear-gradient(to right, #fff, #94a3b8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}



.hero-subtitle {
  margin: 0 auto 2rem;
  max-width: 32rem;
  color: var(--text-muted);
}

.btn-primary {
  display: inline-block;
  padding: 0.875rem 2rem;
  border-radius: 999px;
  background: var(--gradient-primary);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(56, 189, 248, 0.5);
}

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

/* Sections */

.section {
  padding: 3.5rem 0;
}

.section-alt {
  background: var(--bg-alt);
}

.section h2 {
  font-size: 1.6rem;
  margin-bottom: 0.75rem;
}

.section-intro {
  max-width: 32rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

/* Cards */

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

.card {
  background: var(--card-bg);
  border-radius: 1rem;
  padding: 2rem;
  border: 1px solid var(--border-subtle);
  backdrop-filter: blur(12px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: var(--shadow-lg), 0 0 20px rgba(56, 189, 248, 0.05);
}

/* Subtle gradient glow on hover */
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.card:hover::before {
  opacity: 1;
}

.card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-muted);
}

.card-list {
  margin: 0.75rem 0 1rem;
  padding-left: 1.2rem;
  color: var(--text-muted);
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 500;
  color: var(--accent);
}

.project-screenshot {
  margin-top: 1.25rem;
}

.project-screenshot-image {
  display: block;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  border-radius: 1rem;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

/* About */

.about-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .about-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Contact */

.contact-card {
  display: inline-flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1rem 1.25rem;
  border-radius: 0.9rem;
  background: var(--accent-soft);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.contact-card a {
  color: var(--accent);
  font-weight: 500;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--border-subtle);
  background: #020617;
  padding: 1.5rem 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-inner {
  text-align: center;
}

/* Small screens */

@media (max-width: 640px) {
  .header-inner {
    flex-direction: column;
    gap: 0.4rem;
  }

  .logo {
    justify-content: center;
  }

  .nav {
    flex-wrap: wrap;
    justify-content: center;
  }

  .hero {
    padding: 4rem 0 3rem;
  }
}

/* Animation Utilities */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

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

.animate-fade-up {
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
  /* Ensure hidden before animation */
}

.delay-100 {
  animation-delay: 0.1s;
}

.delay-200 {
  animation-delay: 0.2s;
}

.delay-300 {
  animation-delay: 0.3s;
}