/* Osiris Berbesia — landing palette: #0B0E14, #FF6B00, #A5D8FF */

:root {
  --bg-deep: #0b0e14;
  --bg-elevated: rgba(18, 24, 36, 0.65);
  --accent-orange: #ff6b00;
  --accent-orange-soft: rgba(255, 107, 0, 0.35);
  --accent-cyan: #a5d8ff;
  --text-heading: #ffffff;
  --text-body: rgba(230, 235, 245, 0.82);
  --text-muted: rgba(165, 216, 255, 0.55);
  --border-glow: linear-gradient(135deg, rgba(255, 107, 0, 0.6), rgba(165, 216, 255, 0.45));
  --radius-lg: 20px;
  --radius-pill: 9999px;
  --font-sans: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --max-width: 1100px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  letter-spacing: 0.01em;
  color: var(--text-body);
  background: var(--bg-deep);
  overflow-x: hidden;
}

/* Background: glow + topo lines + dot grid */
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.bg-glow {
  position: absolute;
  width: 140%;
  height: 80%;
  top: -20%;
  left: -20%;
  background: radial-gradient(ellipse at 30% 20%, rgba(255, 107, 0, 0.18) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 60%, rgba(165, 216, 255, 0.08) 0%, transparent 45%);
}

.bg-topo {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 600'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0%25' y1='0%25' x2='100%25' y2='100%25'%3E%3Cstop offset='0%25' style='stop-color:%23ff6b00;stop-opacity:0.25'/%3E%3Cstop offset='100%25' style='stop-color:%23a5d8ff;stop-opacity:0.1'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath fill='none' stroke='url(%23g)' stroke-width='0.8' d='M0 400 Q200 380 400 420 T800 400 M0 320 Q250 300 500 340 T800 300 M0 240 Q180 220 400 260 T800 220 M0 160 Q300 140 600 180 T800 140'/%3E%3Cpath fill='none' stroke='rgba(255,107,0,0.15)' stroke-width='0.6' d='M0 480 Q400 460 800 500 M100 100 Q400 80 700 120'/%3E%3C/svg%3E");
  background-size: cover;
  background-position: center top;
}

.bg-dots {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 45%;
  height: 45%;
  opacity: 0.4;
  background-image: radial-gradient(circle, rgba(255, 107, 0, 0.45) 1px, transparent 1px);
  background-size: 18px 18px;
  mask-image: linear-gradient(to top left, black 30%, transparent 75%);
}

.site-wrap {
  position: relative;
  z-index: 1;
}

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: var(--accent-orange);
}

/* Header nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 0.75rem 1.25rem;
  backdrop-filter: blur(12px);
  background: rgba(11, 14, 20, 0.75);
  border-bottom: 1px solid rgba(165, 216, 255, 0.08);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.logo {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-heading);
  letter-spacing: -0.02em;
}

.logo span {
  color: var(--accent-orange);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.5rem 1.25rem;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text-body);
  font-size: 0.92rem;
  font-weight: 500;
}

.nav-links a:hover {
  color: var(--accent-cyan);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.35rem;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-heading);
  background: rgba(18, 24, 36, 0.85);
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  text-decoration: none;
  position: relative;
}

.btn::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: var(--border-glow);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 32px var(--accent-orange-soft);
  color: var(--text-heading);
}

.btn-primary {
  background: rgba(255, 107, 0, 0.12);
}

.btn .icon {
  width: 1.1em;
  height: 1.1em;
  flex-shrink: 0;
}

/* Sections */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

section {
  margin-bottom: 3.5rem;
  scroll-margin-top: 5rem;
}

.hero {
  padding-top: 1.5rem;
  padding-bottom: 1rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  margin-bottom: 1.25rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-cyan);
  background: rgba(165, 216, 255, 0.08);
  border-radius: var(--radius-pill);
  border: 1px solid rgba(165, 216, 255, 0.2);
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 5vw, 2.85rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-heading);
}

.hero h1 .gradient-word {
  background: linear-gradient(120deg, var(--accent-orange), #ffb347);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  max-width: 36rem;
  margin: 0 0 1.75rem;
  font-size: 1.08rem;
  color: var(--text-body);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.hero-meta strong {
  color: var(--accent-cyan);
  font-weight: 600;
}

/* Cards / glass */
.glass {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(165, 216, 255, 0.1);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(10px);
}

.section-title {
  margin: 0 0 1.25rem;
  font-size: clamp(1.35rem, 3vw, 1.6rem);
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -0.02em;
}

.section-intro {
  margin: 0 0 1.5rem;
  max-width: 42rem;
}

/* About */
.about-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 720px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.about-card {
  padding: 1.5rem 1.5rem 1.35rem;
}

.about-card p {
  margin: 0 0 0.85rem;
}

.about-card p:last-child {
  margin-bottom: 0;
}

blockquote {
  margin: 0;
  padding: 1rem 1.25rem;
  font-style: italic;
  color: var(--text-muted);
  border-left: 3px solid var(--accent-orange);
  background: rgba(255, 107, 0, 0.06);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

blockquote cite {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  font-style: normal;
  color: var(--accent-cyan);
}

/* Skills */
.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-body);
  background: rgba(18, 24, 36, 0.9);
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 107, 0, 0.25);
}

.tag.highlight {
  border-color: rgba(165, 216, 255, 0.35);
  color: var(--accent-cyan);
}

/* Project grid */
.projects-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 640px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.project-card {
  padding: 1.35rem 1.4rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover {
  border-color: rgba(255, 107, 0, 0.35);
  box-shadow: 0 12px 48px rgba(255, 107, 0, 0.08);
}

.project-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
}

.project-card p {
  margin: 0 0 1rem;
  flex: 1;
  font-size: 0.92rem;
}

.project-card .link-row {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.badge-beta {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: rgba(255, 107, 0, 0.2);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 107, 0, 0.4);
}

/* Contact */
.contact-block {
  padding: 2rem 1.75rem;
  text-align: center;
  background: linear-gradient(165deg, rgba(18, 24, 36, 0.85), rgba(11, 14, 20, 0.6));
}

.contact-block .section-title {
  margin-bottom: 0.5rem;
}

.contact-block p {
  margin: 0 0 1.25rem;
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}

.email-link {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--accent-cyan);
  word-break: break-all;
}

.email-link:hover {
  color: var(--accent-orange);
}

/* Footer */
.site-footer {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
  border-top: 1px solid rgba(165, 216, 255, 0.08);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  text-align: center;
}

.footer-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(18, 24, 36, 0.9);
  border: 1px solid rgba(165, 216, 255, 0.15);
  color: var(--text-heading);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.footer-social a:hover {
  border-color: var(--accent-orange);
  box-shadow: 0 0 24px var(--accent-orange-soft);
  color: var(--accent-orange);
}

.footer-social svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.footer-copy {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 100;
  width: 48px;
  height: 48px;
  display: none;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(18, 24, 36, 0.95);
  border: 1px solid rgba(255, 107, 0, 0.4);
  color: var(--accent-orange);
  cursor: pointer;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.back-to-top.visible {
  display: flex;
}

.back-to-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px var(--accent-orange-soft);
}

.back-to-top svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

@media (max-width: 480px) {
  .nav-links {
    width: 100%;
    justify-content: flex-start;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    justify-content: center;
  }
}
