/* SECTIONS (common) */
section {
  position: relative;
  width: 100%;
  height: 100%;
}

.section-inner {
  position: relative;
  z-index: 1;
  padding: 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.section-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 4px;
  margin-bottom: 1rem;
  opacity: 0.8;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.section-subtitle {
  color: var(--text-primary);
  font-size: 1.1rem;
  max-width: 600px;
  margin-bottom: 5rem;
}

/* MAIN (title screen) */
#main .section-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  overflow: visible;
  padding: 0;
}

/* GladOS title — first screen 100vh */
#main .hero-center {
  flex: none;
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Subtitle — transitional block, scroll-linked reveal */
.subtitle-block {
  flex: none;
  height: 60vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

/* HERO (personas + chat) */
#hero {
  overflow-x: clip;
  overflow-y: visible;
}
#hero .section-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: 2rem;
  padding-bottom: 2rem;
  overflow: visible;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  background: var(--bg-secondary);
}

.hero-badge span { color: var(--accent-green); }

.hero-center {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(4.5rem, 14vw, 9rem);
  font-weight: 700;
  letter-spacing: -3px;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 2;
  cursor: default;
}

.hero-letter {
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform;
}

.hero-letter-glad {
  color: var(--accent);
}

.hero-letter-os {
  background: linear-gradient(135deg, var(--accent-purple), var(--accent-pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}


.hero-subtitle {
  font-size: 1.3rem;
  color: var(--text-primary);
  max-width: 600px;
  margin: 0 auto;
  font-weight: 300;
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero-subtitle .sub-word {
  display: inline-block;
  white-space: nowrap;
}

.hero-subtitle .sub-char {
  display: inline-block;
  will-change: opacity, transform;
}

/* Scroll-down arrow at bottom of title screen */
.scroll-arrow {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  animation: arrowBounce 2s ease-in-out infinite;
  opacity: 0.6;
  cursor: pointer;
  transition: opacity 0.3s;
}

.scroll-arrow:hover {
  opacity: 1;
}

.scroll-arrow svg {
  width: 32px;
  height: 32px;
  stroke: var(--accent);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.scroll-arrow--sub {
  position: relative;
  bottom: auto;
  left: auto;
  transform: none;
  margin-top: calc(2rem + 20px);
  opacity: 0;
  animation: arrowBounceSub 2s ease-in-out infinite;
}

@keyframes arrowBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(12px); }
}

@keyframes arrowBounceSub {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(12px); }
}

/* MOBILE: fix hero-center centering (iOS 100vh includes browser chrome) */
@media (max-width: 768px) {
  #main .hero-center {
    height: 100dvh;
    flex: none;
  }
}

.hero-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  position: relative;
  z-index: 2;
}

.hero-chat-intro {
  margin-top: 3rem;
  text-align: center;
}

.hero-chat-intro .section-label {
  margin-bottom: 0.5rem;
}

.hero-chat-intro .section-title {
  margin-bottom: 0.3rem;
}

.hero-chat-intro .section-subtitle {
  margin: 0 auto;
  max-width: 500px;
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-primary);
  box-shadow: 0 0 30px rgba(88, 166, 255, 0.3);
  will-change: transform;
}

.btn-primary:hover {
  box-shadow: 0 0 50px rgba(88, 166, 255, 0.5);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-outline {
  background: transparent;
  color: var(--accent-purple);
  border: 1px solid var(--accent-purple);
}

.btn-outline:hover {
  background: rgba(167, 139, 250, 0.1);
  box-shadow: 0 0 30px rgba(167, 139, 250, 0.3);
  transform: translateY(-2px);
}

.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* fullpage.js: fp-overflow прозрачен, section-inner управляет layout */
.fp-overflow {
  width: 100%;
  height: 100%;
}

#hero.fp-section {
  overflow-x: clip;
  overflow-y: visible;
}
