/* BROKEY — brokey.in marketing site */

:root {
  --bg: #060a12;
  --bg-secondary: #0b101c;
  --surface: rgba(17, 24, 39, 0.72);
  --surface-elevated: rgba(27, 36, 54, 0.9);
  --border: rgba(255, 255, 255, 0.08);
  --border-focus: #2dd4bf;
  --primary: #6ee7a8;
  --primary-muted: #a7f3d0;
  --primary-dim: rgba(110, 231, 168, 0.14);
  --teal: #00d4a4;
  --cyan: #22d3ee;
  --text: #f8fafc;
  --text-secondary: #94a3b8;
  --text-tertiary: #64748b;
  --gradient-top: #0d3d38;
  --gradient-mid: #0a1628;
  --radius: 16px;
  --radius-lg: 24px;
  --shadow-glow: 0 0 60px -12px rgba(110, 231, 168, 0.35);
  --font: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

/* Background effects */
.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black 20%, transparent 70%);
}

.bg-glow {
  position: fixed;
  z-index: -1;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}

.bg-glow--1 {
  width: 600px;
  height: 600px;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(13, 61, 56, 0.6) 0%, transparent 70%);
}

.bg-glow--2 {
  width: 400px;
  height: 400px;
  bottom: 10%;
  right: -100px;
  background: radial-gradient(circle, rgba(110, 231, 168, 0.12) 0%, transparent 70%);
}

/* Layout */
.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 0;
  transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
}

.header.scrolled {
  background: rgba(6, 10, 18, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.04em;
}

.logo__img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  object-fit: cover;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__link {
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: color 0.2s;
}

.nav__link:hover {
  color: var(--primary);
}

.nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--teal) 100%);
  color: #0a2e1c;
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: 999px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.nav__cta:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

.menu-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero */
.hero {
  padding: 8rem 0 5rem;
  text-align: center;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: var(--primary-dim);
  border: 1px solid rgba(110, 231, 168, 0.25);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--primary);
  margin-bottom: 1.5rem;
}

.hero__badge-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero__title {
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

.hero__title span {
  background: linear-gradient(135deg, var(--primary) 0%, var(--cyan) 50%, var(--teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__tagline {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  color: var(--text-tertiary);
  margin-bottom: 1.25rem;
}

.hero__subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 2.5rem;
}

.hero__stores {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3.5rem;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  min-width: 200px;
}

.store-btn:hover {
  border-color: rgba(110, 231, 168, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px -8px rgba(0, 0, 0, 0.5);
}

.store-btn__icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.store-btn__text {
  text-align: left;
}

.store-btn__label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.store-btn__name {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}

.store-btn--coming {
  opacity: 0.7;
  cursor: default;
  pointer-events: none;
}

.store-btn--coming .store-btn__name::after {
  content: " — Soon";
  font-size: 0.75rem;
  color: var(--primary);
  font-weight: 500;
}

/* Phone mockup */
.hero__mockup {
  position: relative;
  max-width: 320px;
  margin: 0 auto;
}

.phone-frame {
  position: relative;
  background: linear-gradient(145deg, #1b2436 0%, #111827 100%);
  border-radius: 36px;
  padding: 12px;
  border: 1px solid var(--border);
  box-shadow:
    0 25px 80px -20px rgba(0, 0, 0, 0.6),
    var(--shadow-glow);
}

.phone-frame__screen {
  border-radius: 28px;
  overflow: hidden;
  background: var(--bg-secondary);
  aspect-ratio: 9 / 19.5;
}

.phone-frame__screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.phone-frame__notch {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 24px;
  background: #000;
  border-radius: 20px;
  z-index: 2;
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.75rem;
  text-align: center;
}

.section__title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.section__subtitle {
  text-align: center;
  color: var(--text-secondary);
  max-width: 540px;
  margin: 0 auto 3rem;
}

/* Features */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.feature-card {
  padding: 1.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(12px);
  transition: border-color 0.25s, transform 0.25s;
}

.feature-card:hover {
  border-color: rgba(110, 231, 168, 0.3);
  transform: translateY(-4px);
}

.feature-card__icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-dim);
  border-radius: 12px;
  margin-bottom: 1.25rem;
  color: var(--primary);
}

.feature-card__icon svg {
  width: 24px;
  height: 24px;
}

.feature-card__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.feature-card__text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1.5rem;
  padding: 2.5rem;
  background: linear-gradient(135deg, rgba(13, 61, 56, 0.3) 0%, var(--surface) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-top: 3rem;
}

.stat__value {
  font-size: 2rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat__label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  counter-reset: step;
}

.step {
  text-align: center;
  position: relative;
}

.step::before {
  counter-increment: step;
  content: counter(step);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin: 0 auto 1.25rem;
  background: var(--primary-dim);
  border: 1px solid rgba(110, 231, 168, 0.3);
  border-radius: 50%;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
}

.step__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.step__text {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Download CTA */
.cta-section {
  padding: 5rem 0;
}

.cta-card {
  position: relative;
  overflow: hidden;
  padding: 3.5rem 2rem;
  text-align: center;
  background: linear-gradient(135deg, var(--gradient-top) 0%, var(--gradient-mid) 50%, var(--bg) 100%);
  border: 1px solid rgba(110, 231, 168, 0.2);
  border-radius: var(--radius-lg);
}

.cta-card::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(110, 231, 168, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.cta-card__title {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  margin-bottom: 0.75rem;
  position: relative;
}

.cta-card__text {
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto 2rem;
  position: relative;
}

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

/* Footer */
.footer {
  padding: 3rem 0 2rem;
  border-top: 1px solid var(--border);
}

.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  text-align: center;
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
}

.footer__link {
  font-size: 0.875rem;
  color: var(--text-secondary);
  transition: color 0.2s;
}

.footer__link:hover {
  color: var(--primary);
}

.footer__copy {
  font-size: 0.8rem;
  color: var(--text-tertiary);
}

/* Privacy page */
.legal-page {
  padding: 7rem 0 4rem;
  min-height: 100vh;
}

.legal-page__header {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.legal-page__title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.legal-page__updated {
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

.legal-content {
  max-width: 720px;
}

.legal-content h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 2rem 0 0.75rem;
  color: var(--text);
}

.legal-content h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 1.5rem 0 0.5rem;
  color: var(--text-secondary);
}

.legal-content p,
.legal-content li {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  line-height: 1.7;
}

.legal-content ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.legal-content a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-content a:hover {
  color: var(--primary-muted);
}

/* Delete account page */
.delete-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
  gap: 2.5rem;
  align-items: start;
}

.delete-info {
  max-width: none;
}

.delete-form-card {
  position: sticky;
  top: 6rem;
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: blur(16px);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.25);
}

.delete-form-card__title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.delete-form-card__subtitle {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.delete-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.delete-form__field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.delete-form__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.delete-form__optional {
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text-tertiary);
}

.delete-form__input,
.delete-form__textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.delete-form__input::placeholder,
.delete-form__textarea::placeholder {
  color: var(--text-tertiary);
}

.delete-form__input:focus,
.delete-form__textarea:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(45, 212, 191, 0.15);
}

.delete-form__textarea {
  resize: vertical;
  min-height: 88px;
}

.delete-form__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
  cursor: pointer;
}

.delete-form__checkbox input {
  margin-top: 0.2rem;
  accent-color: var(--teal);
}

.delete-form__error {
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: 1px solid rgba(248, 113, 113, 0.25);
  background: rgba(248, 113, 113, 0.1);
  color: #fecaca;
  font-size: 0.875rem;
}

.delete-form__submit,
.delete-form__secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.9rem 1.25rem;
  border-radius: 12px;
  border: none;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s, opacity 0.2s;
}

.delete-form__submit {
  background: linear-gradient(135deg, var(--teal), #14b8a6);
  color: #041016;
}

.delete-form__submit:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.delete-form__submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.delete-form__secondary {
  margin-top: 1rem;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border: 1px solid var(--border);
}

.delete-form__secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.delete-form__success {
  text-align: center;
}

.delete-form__success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  margin-bottom: 1rem;
  border-radius: 999px;
  background: rgba(110, 231, 168, 0.12);
  color: var(--primary);
}

.delete-form__success-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.delete-form__success-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.delete-form__success-text a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

@media (max-width: 900px) {
  .delete-layout {
    grid-template-columns: 1fr;
  }

  .delete-form-card {
    position: static;
  }
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
  .nav {
    position: fixed;
    top: 0;
    right: 0;
    width: min(280px, 85vw);
    height: 100vh;
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem 1.5rem 2rem;
    background: rgba(6, 10, 18, 0.97);
    backdrop-filter: blur(20px);
    border-left: 1px solid var(--border);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    gap: 1.5rem;
  }

  .nav.open {
    transform: translateX(0);
  }

  .nav__cta {
    width: 100%;
    justify-content: center;
  }

  .menu-toggle {
    display: flex;
    z-index: 101;
  }

  .hero {
    padding: 6.5rem 0 3.5rem;
  }

  .hero__stores {
    flex-direction: column;
    align-items: stretch;
  }

  .store-btn {
    justify-content: center;
    min-width: unset;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
  }

  .section {
    padding: 3.5rem 0;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
    padding: 1.5rem;
    gap: 1rem;
  }

  .stat__value {
    font-size: 1.5rem;
  }

  .cta-card {
    padding: 2.5rem 1.25rem;
  }

  .footer__links {
    flex-direction: column;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .hero__title {
    font-size: 2.25rem;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .steps {
    grid-template-columns: 1fr;
  }
}
