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

:root {
  --green-deep:   #0d3b1e;
  --green-mid:    #145a32;
  --green-bright: #27ae60;
  --green-light:  #52d68a;
  --green-glow:   #a8ffcb;
  --cream:        #f5f0e8;
  --white:        #ffffff;
}

html, body {
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Montserrat', sans-serif;
  background: var(--green-deep);
  color: var(--white);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ── animated mesh background ── */
.bg {
  position: fixed; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 30%, #1a6b3a 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 80% 70%, #0a4220 0%, transparent 60%),
    radial-gradient(ellipse 40% 40% at 55% 10%, #2d8c52 0%, transparent 50%),
    linear-gradient(160deg, #0b2e14 0%, #1a5c34 50%, #0d3b1e 100%);
  animation: bgPulse 10s ease-in-out infinite alternate;
}
@keyframes bgPulse {
  0%   { filter: brightness(1)   saturate(1);   }
  100% { filter: brightness(1.1) saturate(1.15); }
}

.bg::after {
  content: '';
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: .35;
  pointer-events: none;
}

/* ── layout ── */
.shell {
  position: relative; z-index: 1;
  display: flex; flex-direction: column;
  min-height: 100vh;
  padding: 0 clamp(1.5rem, 5vw, 4rem);
}

/* ── NAV ── */
nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  animation: fadeDown .7s ease both;
}
.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.7rem; font-weight: 900; letter-spacing: .04em;
  color: var(--green-glow);
  text-shadow: 0 0 30px rgba(82,214,138,.4);
}
.logo span { color: var(--white); }

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

.btn-cabinet {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .55rem 1.3rem;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 50px;
  color: var(--white);
  font-family: 'Montserrat', sans-serif;
  font-size: .82rem; font-weight: 600; letter-spacing: .06em;
  text-decoration: none;
  backdrop-filter: blur(8px);
  transition: background .25s, border-color .25s, transform .2s;
  cursor: pointer;
  background-color: transparent;
}
.btn-cabinet:hover {
  background: rgba(255,255,255,.14);
  border-color: rgba(255,255,255,.4);
  transform: translateY(-1px);
}
.btn-cabinet svg { width: 15px; height: 15px; fill: var(--green-light); }

.btn-contact {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .55rem 1.4rem;
  background: var(--green-bright);
  border: none; border-radius: 50px;
  color: var(--white);
  font-family: 'Montserrat', sans-serif;
  font-size: .82rem; font-weight: 700; letter-spacing: .06em;
  cursor: pointer;
  position: relative;
  transition: transform .2s, box-shadow .25s;
  box-shadow: 0 4px 20px rgba(39,174,96,.45);
}
.btn-contact:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(39,174,96,.6);
}

.contact-wrap { position: relative; }
.dropdown {
  position: absolute; top: calc(100% + .6rem); right: 0;
  background: rgba(10,40,22,.92);
  border: 1px solid rgba(82,214,138,.2);
  border-radius: 14px;
  padding: .6rem;
  display: flex; flex-direction: column; gap: .4rem;
  min-width: 190px;
  backdrop-filter: blur(16px);
  opacity: 0; pointer-events: none;
  transform: translateY(-6px);
  transition: opacity .22s, transform .22s;
  z-index: 99;
}
.dropdown.open { opacity: 1; pointer-events: all; transform: translateY(0); }
.dropdown a {
  display: flex; align-items: center; gap: .7rem;
  padding: .65rem .9rem;
  border-radius: 10px;
  color: var(--white);
  text-decoration: none;
  font-size: .84rem; font-weight: 500;
  transition: background .18s;
}
.dropdown a:hover { background: rgba(255,255,255,.08); }
.dropdown a .icon { font-size: 1.1rem; }

/* ── HERO ── */
.hero {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  gap: 1.1rem;
  padding: 1rem 0 1.5rem;
}

.illustration {
  width: clamp(130px, 18vw, 220px);
  filter: drop-shadow(0 0 40px rgba(82,214,138,.35));
  animation: floatY 5s ease-in-out infinite, fadeUp .9s ease .2s both;
}
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-14px); }
}

.headline { animation: fadeUp .9s ease .35s both; }
.headline h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -.01em;
  color: var(--white);
}
.headline h1 .brand {
  color: var(--green-light);
  text-shadow: 0 0 40px rgba(82,214,138,.5);
}
.headline p {
  margin-top: 1rem;
  font-size: clamp(.95rem, 1.6vw, 1.15rem);
  font-weight: 300;
  color: rgba(255,255,255,.6);
  letter-spacing: .04em;
}

.deco-line {
  width: 60px; height: 3px;
  background: linear-gradient(90deg, var(--green-bright), var(--green-light));
  border-radius: 2px;
  margin: 0 auto;
  animation: expandLine .8s ease .6s both;
}
@keyframes expandLine {
  from { width: 0; opacity: 0; }
  to   { width: 60px; opacity: 1; }
}

.tags {
  display: flex; gap: .7rem; flex-wrap: wrap; justify-content: center;
  animation: fadeUp .9s ease .5s both;
}
.tag {
  padding: .4rem 1rem;
  background: rgba(39,174,96,.12);
  border: 1px solid rgba(39,174,96,.25);
  border-radius: 50px;
  font-size: .78rem; font-weight: 600; letter-spacing: .05em;
  color: var(--green-light);
}

/* ── PHONE MOCKUP ── */
.app-section {
  animation: fadeUp .9s ease .65s both;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
}
.app-label {
  font-size: .78rem; font-weight: 600; letter-spacing: .12em;
  color: rgba(255,255,255,.4);
  text-transform: uppercase;
}
.phone-wrap {
  position: relative;
  cursor: pointer;
  display: flex;
  align-items: flex-end;
  gap: 1.4rem;
}

.phone-svg {
  width: clamp(70px, 9vw, 100px);
  filter: drop-shadow(0 8px 28px rgba(39,174,96,.3));
  transition: filter .3s, transform .3s;
  animation: floatPhone 6s ease-in-out infinite;
}
.phone-svg:hover { filter: drop-shadow(0 12px 40px rgba(82,214,138,.55)); transform: scale(1.04); }
@keyframes floatPhone {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50%       { transform: translateY(-8px) rotate(2deg); }
}

.store-badges { display: flex; flex-direction: column; gap: .65rem; }
.badge {
  display: flex; align-items: center; gap: .7rem;
  padding: .6rem 1.1rem;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  text-decoration: none;
  color: var(--white);
  backdrop-filter: blur(8px);
  transition: background .22s, border-color .22s, transform .2s;
  min-width: 155px;
}
.badge:hover {
  background: rgba(255,255,255,.13);
  border-color: rgba(82,214,138,.4);
  transform: translateX(3px);
}
.badge-icon { font-size: 1.4rem; line-height: 1; }
.badge-text { display: flex; flex-direction: column; }
.badge-sub  { font-size: .62rem; font-weight: 400; color: rgba(255,255,255,.5); letter-spacing: .04em; }
.badge-name { font-size: .88rem; font-weight: 700; letter-spacing: .02em; }

/* ── FOOTER ── */
footer {
  position: relative; z-index: 1;
  text-align: center;
  padding: 1.2rem 0;
  font-size: .72rem; font-weight: 300;
  color: rgba(255,255,255,.25);
  letter-spacing: .07em;
  border-top: 1px solid rgba(255,255,255,.05);
}

/* ── keyframes ── */
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ═══════════════════════════════════════
   AUTH MODAL
═══════════════════════════════════════ */
.auth-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(5, 20, 10, .75);
  backdrop-filter: blur(10px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  opacity: 0; pointer-events: none;
  transition: opacity .28s;
}
.auth-overlay.open {
  opacity: 1; pointer-events: all;
}

.auth-modal {
  background: linear-gradient(145deg, #0f3d20, #0a2812);
  border: 1px solid rgba(82,214,138,.18);
  border-radius: 24px;
  width: 100%; max-width: 420px;
  padding: 2rem 2rem 2.2rem;
  box-shadow: 0 24px 80px rgba(0,0,0,.6), 0 0 0 1px rgba(82,214,138,.06);
  transform: translateY(20px) scale(.97);
  transition: transform .28s cubic-bezier(.34,1.56,.64,1);
  position: relative;
}
.auth-overlay.open .auth-modal {
  transform: translateY(0) scale(1);
}

.auth-close {
  position: absolute; top: 1rem; right: 1rem;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 50%;
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.6);
  font-size: 1rem; line-height: 1;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.auth-close:hover { background: rgba(255,255,255,.14); color: var(--white); }

/* tabs */
.auth-tabs {
  display: flex;
  background: rgba(255,255,255,.05);
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 1.8rem;
}
.auth-tab {
  flex: 1;
  padding: .55rem;
  text-align: center;
  font-family: 'Montserrat', sans-serif;
  font-size: .82rem; font-weight: 600; letter-spacing: .04em;
  color: rgba(255,255,255,.45);
  border: none; background: none;
  border-radius: 9px;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.auth-tab.active {
  background: var(--green-bright);
  color: var(--white);
  box-shadow: 0 2px 12px rgba(39,174,96,.4);
}

/* form panels */
.auth-panel { display: none; }
.auth-panel.active { display: block; }

.auth-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem; font-weight: 700;
  color: var(--white);
  margin-bottom: .35rem;
}
.auth-sub {
  font-size: .78rem; color: rgba(255,255,255,.4);
  margin-bottom: 1.5rem;
  font-weight: 400;
}

/* fields */
.auth-field {
  margin-bottom: 1rem;
}
.auth-field label {
  display: block;
  font-size: .73rem; font-weight: 600; letter-spacing: .05em;
  color: rgba(255,255,255,.5);
  margin-bottom: .4rem;
  text-transform: uppercase;
}
.auth-input-wrap {
  position: relative;
}
.auth-input-wrap .prefix {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  font-size: .85rem; color: rgba(255,255,255,.4);
  pointer-events: none;
}
.auth-field input {
  width: 100%;
  padding: .72rem 1rem;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  color: var(--white);
  font-family: 'Montserrat', sans-serif;
  font-size: .88rem;
  outline: none;
  transition: border-color .2s, background .2s;
}
.auth-field input.has-prefix { padding-left: 3.2rem; }
.auth-field input::placeholder { color: rgba(255,255,255,.25); }
.auth-field input:focus {
  border-color: var(--green-bright);
  background: rgba(39,174,96,.07);
}

.auth-error {
  font-size: .75rem; color: #ff7575;
  margin-top: .3rem;
  display: none;
}
.auth-error.show { display: block; }

/* submit */
.auth-submit {
  width: 100%; margin-top: 1.4rem;
  padding: .82rem;
  background: var(--green-bright);
  border: none; border-radius: 14px;
  color: var(--white);
  font-family: 'Montserrat', sans-serif;
  font-size: .9rem; font-weight: 700; letter-spacing: .05em;
  cursor: pointer;
  box-shadow: 0 4px 22px rgba(39,174,96,.4);
  transition: transform .2s, box-shadow .2s;
}
.auth-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(39,174,96,.55);
}
.auth-submit:active { transform: translateY(0); }

.auth-switch {
  text-align: center;
  margin-top: 1.1rem;
  font-size: .78rem; color: rgba(255,255,255,.4);
}
.auth-switch button {
  background: none; border: none;
  color: var(--green-light);
  font-family: 'Montserrat', sans-serif;
  font-size: .78rem; font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── role selector ── */
.role-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .6rem;
  margin-top: .1rem;
}
.role-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .35rem;
  padding: .75rem .4rem;
  background: rgba(255,255,255,.05);
  border: 1.5px solid rgba(255,255,255,.1);
  border-radius: 14px;
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .15s;
  text-align: center;
  user-select: none;
}
.role-card:hover {
  background: rgba(39,174,96,.1);
  border-color: rgba(39,174,96,.35);
  transform: translateY(-2px);
}
.role-card input[type="radio"] {
  display: none;
}
.role-card:has(input:checked) {
  background: rgba(39,174,96,.18);
  border-color: var(--green-bright);
  box-shadow: 0 0 0 3px rgba(39,174,96,.15);
}
.role-icon { font-size: 1.5rem; line-height: 1; }
.role-name {
  font-size: .7rem;
  font-weight: 600;
  color: rgba(255,255,255,.75);
  letter-spacing: .02em;
  line-height: 1.3;
}

/* success state */
.auth-success {
  text-align: center;
  padding: 1rem 0 .5rem;
  display: none;
}
.auth-success.show { display: block; }
.auth-success-icon {
  font-size: 3rem;
  margin-bottom: .8rem;
}
.auth-success h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--green-light);
  margin-bottom: .4rem;
}
.auth-success p {
  font-size: .8rem;
  color: rgba(255,255,255,.45);
}
