@import url("https://fonts.googleapis.com/css2?family=Ubuntu+Mono:wght@400;700&display=swap");
@import url('https://cdn-uicons.flaticon.com/3.0.0/uicons-bold-straight/css/uicons-bold-straight.css');
@import url('https://cdn-uicons.flaticon.com/3.0.0/uicons-regular-rounded/css/uicons-regular-rounded.css');

:root {
  --bg: #0e1016;
  --panel: rgba(225, 225, 225, 0.06);
  --panel-2: rgba(255, 255, 255, 0.09);
  --text: rgba(255, 255, 255, 0.92);
  --muted: rgba(255, 255, 255, 0.68);
  --line: rgba(255, 255, 255, 0.12);
  --brand: #7c3aed;
  --brand-2: #22c55e;
  --shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
  --radius: 18px;
  --radius2: 26px;
  --container: 1120px;
  --font-mono: "Ubuntu Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;

  --terminal-color: #4E9A06;
  --magenta: #FF55FF;

  --sm: 12px;
  --md: 16px;
  --lg: 20px;
}

.terminal-color {
  color: var(--terminal-color);
}

* {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
  background: white;
  color: var(--bg);
  font-family: var(--font-mono);

  &::-webkit-scrollbar {
    width: 1px;
    height: 1px;
  }

  &::-webkit-scrollbar-button {
    width: 1px;
    height: 1px;
  }

  &::-webkit-scrollbar-thumb {
    background: #e1e1e1;
    border: 0px none #ffffff;
    border-radius: 50px;
  }

  &::-webkit-scrollbar-thumb:hover {
    background: #ffffff;
  }

  &::-webkit-scrollbar-thumb:active {
    background: #000000;
  }

  &::-webkit-scrollbar-track {
    background: #666666;
    border: 0px none #ffffff;
    border-radius: 1px;
  }

  &::-webkit-scrollbar-track:hover {
    background: #666666;
  }

  &::-webkit-scrollbar-track:active {
    background: #333333;
  }
  
  &::-webkit-scrollbar-corner {
    background: transparent;
  }
}

i {
  font-size: calc(var(--sm) / 1.25);
}

section {
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

section.vertical {
  flex-direction: column;
  gap: var(--sm);
}

.container {
  max-width: var(--container);
  width: 100%;
  height: auto;
  position: relative;
}

.lucas-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sm);

  .featured-name {
    font-size: calc(var(--lg) * 2);
  }
}

.lucas-video {
  width: 125px;
  overflow: hidden;
  border-radius: 9999px;
  aspect-ratio: 1/1;
  cursor: pointer;

  video {
    width: 215%;
    transform: translateX(-48px);
  }
}

.contact-actions ul {
  gap: var(--md);
  list-style: none;
  margin-bottom: var(--sm);
  justify-content: space-between;
}

.contact-actions ul li {
  border-radius: var(--sm);
}

.contact-actions ul li a {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--sm);
  justify-content: space-between;
  padding: calc(var(--sm) / 1.5);
}

.actions {
  display: flex;
  margin-top: var(--sm);
  font-size: var(--md);
}

.actions a {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--sm);
  justify-content: space-between;
  padding: calc(var(--sm) / 1.5);
}

a > i {
  opacity: .5;
}

a:hover, a:hover i {
  color: var(--magenta);
  opacity: 1;
}

i {
  color: inherit;
  font-size: inherit;
}

button {
  padding: calc(var(--sm) / 1.5);
  border: 0;
  cursor: pointer;
}

button.large-text i {
  font-size: var(--lg);
}

button i {
  font-size: var(--md);
  background: transparent;
}

.float-detail {
  position: absolute;
  background: white;
  color: var(--bg);
  border-radius: 999px;
  transform: translate(5px, -55px);
  aspect-ratio: 1/1;
}

.lucas-resume {
  height: 0;
  opacity: 0;
  padding: var(--sm);
  overflow: hidden;
  background: white;
  border-radius: var(--tt-radius);
  box-shadow: var(--tt-shadow);
  backdrop-filter: blur(10px);
  transition: height .45 ease-in-out;
}

.lucas-resume.active {
  opacity: 1;
  height: 257px;
  border: 1px solid var(--tt-border);
  transition: all .45s ease-in-out;
}

.lucas-resume.inactive {
  height: 0;
  transition: all .45s ease-in-out;
}

.lucas-resume p {
  background: transparent;
}

.lucas-resume p:not(:last-child) {
  margin-bottom: var(--sm);
}

.down {
  display: flex;
  align-items: center;
  justify-content: center;
}

.down {
  font-size: calc(var(--lg) * 1.5);
  position: absolute;
  bottom: 0;
  width: 100%;
  cursor: pointer;
  margin-bottom: var(--sm);
}

html {
  scroll-behavior: smooth;
}

h1, .title {
  font-size: calc(var(--lg) * 2.5);
}

.title {
  margin-bottom: var(--lg);
}

.history {
  padding: var(--lg);
  overflow-y: auto;
  min-height: 0;
  max-height: 500px;
}

.year {
  display: flex;
  gap: var(--md);
  align-items: start;
  justify-content: center;
  position: relative;
  margin-bottom: var(--lg);
}

.year .year-content {
  min-height: 100px;
}

.year .year-gap {
  height: 1px;
  background: var(--bg);
  width: 50px;
}

.year .years-numbers {
  display: flex;
  align-items: center;
  gap: var(--sm);
}

.year .year-number {
  display: flex;
  justify-content: center;
}

/* =========================
   Responsive patch
   ========================= */

/* 1) Base responsiva */
html {
  font-size: 16px;
}

body {
  min-height: 100vh;
}

/* Evita layout estourando em telas pequenas */
.container {
  padding: 0 var(--md);
}

/* Tipografia fluida (desktop -> mobile) */
:root {
  --sm: clamp(10px, 1.1vw, 12px);
  --md: clamp(14px, 1.4vw, 16px);
  --lg: clamp(18px, 2.0vw, 20px);
  --container: 1120px;
}

h1, .title {
  font-size: clamp(28px, 4vw, calc(var(--lg) * 2.5));
}

.lucas-info .featured-name {
  font-size: clamp(26px, 4.2vw, calc(var(--lg) * 2));
}

/* 2) Section: não força 100vh em mobile (bug clássico por barra do navegador) */
section {
  min-height: 100vh;
  height: auto;
  padding: clamp(16px, 4vw, 32px) 0;
}

/* 3) Ações e listas: wrap automático */
.actions {
  flex-wrap: wrap;
  gap: var(--sm);
}

.contact-actions ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sm);
  flex-direction: column;
}

/* 4) History: altura mais flexível e melhor no mobile */
.history {
  max-height: min(70vh, 560px);
  padding: clamp(12px, 3vw, var(--lg));
}

/* 5) Timeline: evita apertar demais */
.year {
  flex-wrap: wrap;
  justify-content: flex-start;
}

.year .year-gap {
  width: clamp(24px, 8vw, 50px);
}

/* 6) Resume: remove altura fixa e melhora animação */
.lucas-resume {
  max-height: 0;
  height: auto;
  opacity: 0;
  transition: max-height .45s ease-in-out, opacity .25s ease-in-out;
}

.lucas-resume.active {
  opacity: 1;
  max-height: 520px; /* suficiente pra mobile e desktop */
}

/* =========================
   Breakpoints
   ========================= */

/* Tablets */
@media (max-width: 900px) {
  .lucas-info {
    align-items: flex-start;
  }

  .lucas-video {
    width: 96px;
    height: 96px;
  }

  .lucas-resume {
    overflow-y: auto;
  }
}

/* Mobile */
@media (max-width: 640px) {
  .container {
    padding: 0 14px;
  }

  .lucas-info {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--md);
  }

  .lucas-video {
    width: 84px;
    height: 84px;
  }

  .contact-actions ul li,
  .actions a,
  .contact-actions ul li a {
    width: 100%;
  }

  .down {
    font-size: clamp(22px, 6vw, 30px);
    margin-bottom: 14px;
  }

  .year {
    gap: var(--sm);
  }

  .year .year-gap {
    display: none;
  }

  .year .years-numbers {
    width: 100%;
    justify-content: flex-start;
  }
}

/* Mobile pequeno */
@media (max-width: 380px) {
  .lucas-video {
    width: 72px;
    height: 72px;
  }

  button.large-text i {
    font-size: clamp(18px, 6vw, var(--lg));
  }
}