:root {
  --fyule-purple: #4a1d8a;
  --fyule-purple-deep: #2f0f5c;
  --fyule-purple-mid: #5b2aa6;
  --fyule-lime: #c8f000;
  --fyule-lime-deep: #a8d000;
  --fyule-gold: #d4a017;
  --fyule-ink: #160824;
  --fyule-muted: #5a5368;
  --fyule-surface: #f4f1f8;
  --fyule-card: #ffffff;
  --fyule-border: rgba(74, 29, 138, 0.16);
  --fyule-shadow: 0 8px 24px rgba(47, 15, 92, 0.08);
  --fyule-radius: 10px;
  --fyule-font-display: "Syne", system-ui, sans-serif;
  --fyule-font-body: "DM Sans", system-ui, sans-serif;
}

.fyule-page {
  margin: 0;
  min-height: 100vh;
  font-family: var(--fyule-font-body);
  color: var(--fyule-ink);
  background:
    linear-gradient(180deg, #ebe4f4 0%, var(--fyule-surface) 28%, #f8f7fb 100%);
}

.fyule-main {
  padding: 6.5rem 1.25rem 3rem;
}

.fyule-wrap {
  width: min(760px, 100%);
  margin: 0 auto;
}

.fyule-test-banner,
.fyule-pending-banner {
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  background: rgba(212, 160, 23, 0.12);
  border: 1px solid rgba(212, 160, 23, 0.35);
  color: #6b4a00;
  display: grid;
  gap: 0.25rem;
  animation: fyule-fade-up 0.55s ease both;
}

.fyule-test-banner code {
  font-size: 0.85em;
}

.fyule-brand {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  align-items: center;
  margin-bottom: 1.25rem;
  animation: fyule-fade-up 0.7s ease both;
}

.fyule-brand__logo {
  width: min(200px, 42vw);
  height: auto;
  filter: drop-shadow(0 10px 24px rgba(47, 15, 92, 0.18));
}

.fyule-brand__eyebrow {
  margin: 0 0 0.2rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fyule-purple-mid);
}

.fyule-brand h1 {
  margin: 0;
  font-family: var(--fyule-font-display);
  font-size: clamp(2.4rem, 6vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--fyule-purple-deep);
  line-height: 1;
}

.fyule-brand__tag {
  margin: 0.45rem 0 0.85rem;
  color: var(--fyule-muted);
  font-size: 1.02rem;
}

.fyule-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.fyule-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.55rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
}

.fyule-pill--violet {
  background: rgba(74, 29, 138, 0.12);
  color: var(--fyule-purple);
}

.fyule-pill--lime {
  background: rgba(200, 240, 0, 0.35);
  color: #3d4d00;
}

.fyule-pill--gold {
  background: rgba(212, 160, 23, 0.18);
  color: #6b4a00;
}

.fyule-brochure-bar {
  display: flex;
  justify-content: center;
  padding: 0.7rem 0.85rem;
  margin: 0 0 1rem;
  border-radius: var(--fyule-radius);
  background: linear-gradient(90deg, var(--fyule-lime) 0%, #d8f84a 50%, var(--fyule-lime) 100%);
  border: 1px solid rgba(61, 77, 0, 0.18);
  box-shadow: none;
}

.fyule-brochure-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.15rem;
  border-radius: 8px;
  background: var(--fyule-purple-deep);
  color: #fff !important;
  text-decoration: none !important;
  font-weight: 700;
  font-size: 0.92rem;
  box-shadow: none;
  transition: background 0.15s ease;
}

.fyule-brochure-btn:hover,
.fyule-brochure-btn:focus-visible {
  transform: none;
  background: #220a42;
  box-shadow: none;
}

.fyule-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 1rem;
}

.fyule-btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  font-family: inherit;
  font-weight: 700;
  border-radius: 8px;
  padding: 0.55rem 1rem;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.fyule-btn--ghost {
  background: #fff;
  color: var(--fyule-purple);
  border: 1px solid var(--fyule-border);
}

.fyule-btn--primary {
  background: var(--fyule-purple);
  color: #fff;
}

.fyule-btn:hover {
  transform: none;
}

.fyule-form-card {
  background: var(--fyule-card);
  border-radius: var(--fyule-radius);
  overflow: hidden;
  box-shadow: var(--fyule-shadow);
  border: 1px solid var(--fyule-border);
  border-top: 3px solid var(--fyule-purple);
  animation: fyule-fade-up 0.55s ease both;
}

.fyule-form-card__head {
  padding: 1.5rem 1.5rem 0.75rem;
}

.fyule-form-card__head h2 {
  margin: 0 0 0.4rem;
  font-family: var(--fyule-font-display);
  font-size: 1.55rem;
  color: var(--fyule-purple);
}

.fyule-form-card__head p,
.fyule-hint,
.fyule-privacy {
  margin: 0;
  color: var(--fyule-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.fyule-form-card__body {
  padding: 0.5rem 1.5rem 1.75rem;
}

.fyule-section {
  margin-top: 1.35rem;
  padding-top: 0.35rem;
}

.fyule-section h3 {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fyule-purple);
  font-weight: 800;
}

.fyule-field {
  margin-bottom: 1rem;
}

.fyule-field label,
.fyule-field__legend {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--fyule-ink);
}

.fyule-req {
  color: #c0265a;
}

.fyule-field input:not([type="checkbox"]):not([type="radio"]),
.fyule-field textarea,
.fyule-dialog input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid rgba(74, 29, 138, 0.18);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font: inherit;
  color: var(--fyule-ink);
  background: #fcfbfd;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.fyule-field select {
  width: 100%;
  min-height: 48px;
  padding: 0.7rem 2.75rem 0.7rem 0.85rem;
  border-radius: 12px;
  border: 1px solid var(--fyule-border);
  background: #fff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%234a1d8a' d='M1.2 1.3 6 6.1l4.8-4.8 1.2 1.2L6 8.5 0 2.5z'/%3E%3C/svg%3E")
    no-repeat right 0.95rem center;
  appearance: none;
  -webkit-appearance: none;
  color: var(--fyule-ink);
  font: inherit;
  font-size: 16px;
}

.fyule-field select:focus {
  outline: none;
  border-color: var(--fyule-purple-mid);
  box-shadow: 0 0 0 3px rgba(91, 42, 166, 0.15);
}

.fyule-consent {
  display: inline-flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--fyule-ink);
  cursor: pointer;
}

.fyule-consent input {
  width: 1.15rem !important;
  height: 1.15rem !important;
  min-width: 1.15rem;
  margin-top: 0.15rem;
  accent-color: var(--fyule-purple);
}

.fyule-pick {
  position: relative;
}

.fyule-pick__btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  box-sizing: border-box;
  min-height: 2.85rem;
  border: 1px solid rgba(74, 29, 138, 0.18);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font: inherit;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.4;
  color: var(--fyule-ink);
  background: #fcfbfd;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.fyule-pick__btn:hover {
  border-color: rgba(74, 29, 138, 0.28);
}

.fyule-pick.is-open .fyule-pick__btn,
.fyule-pick__btn:focus-visible {
  outline: none;
  border-color: var(--fyule-purple-mid);
  box-shadow: 0 0 0 3px rgba(91, 42, 166, 0.15);
}

.fyule-pick__label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fyule-pick__label.is-placeholder {
  color: #9ca3af;
  font-weight: 400;
}

.fyule-pick__chevron {
  width: 0.5rem;
  height: 0.5rem;
  border-right: 1.5px solid #8b7fa0;
  border-bottom: 1.5px solid #8b7fa0;
  transform: rotate(45deg) translateY(-2px);
  flex-shrink: 0;
  transition: transform 0.2s ease;
  opacity: 0.85;
}

.fyule-pick.is-open .fyule-pick__chevron {
  transform: rotate(225deg) translateY(-1px);
}

.fyule-pick__list {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  z-index: 40;
  margin: 0;
  padding: 0.4rem;
  list-style: none;
  max-height: 240px;
  overflow: auto;
  border-radius: 14px;
  background: #fff;
  border: 1px solid rgba(74, 29, 138, 0.16);
  box-shadow: 0 18px 40px rgba(47, 15, 92, 0.16);
}

.fyule-pick__list[hidden] {
  display: none !important;
}

.fyule-pick__list li {
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--fyule-ink);
}

.fyule-pick__list li:hover,
.fyule-pick__list li[aria-selected="true"] {
  background: rgba(74, 29, 138, 0.08);
  color: var(--fyule-purple-deep);
}

.fyule-pick__list li[data-value=""] {
  color: #8a819c;
}

.fyule-field-error {
  min-height: 1.1em;
  margin: 0.35rem 0 0;
  color: #b42318;
  font-size: 0.82rem;
  font-weight: 600;
}

.fyule-hint {
  margin-top: 0.35rem;
  font-size: 0.82rem;
}

.fyule-phone {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: stretch;
}

.fyule-phone__prefix {
  display: grid;
  place-items: center;
  padding: 0 0.85rem;
  border: 1px solid rgba(74, 29, 138, 0.18);
  border-right: 0;
  border-radius: 12px 0 0 12px;
  background: #f1ebf8;
  font-weight: 700;
  color: var(--fyule-purple);
}

.fyule-phone input {
  border-radius: 0 12px 12px 0;
}

.fyule-grid--3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}

.fyule-grades {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.7rem;
  padding: 0.95rem;
  border-radius: 18px;
  background: #efe9f7;
  border: 1px solid rgba(74, 29, 138, 0.1);
}

.fyule-grade {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 78px;
  padding: 0.75rem 0.7rem 0.7rem;
  border-radius: 14px;
  background: #fff;
  border: 1.5px solid transparent;
  box-shadow: 0 1px 2px rgba(47, 15, 92, 0.04);
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.fyule-grade:hover {
  border-color: rgba(74, 29, 138, 0.22);
  box-shadow: 0 6px 16px rgba(47, 15, 92, 0.08);
}

.fyule-grade__name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #2a183f;
  line-height: 1.2;
  padding-right: 1.4rem;
}

.fyule-grade input[type="radio"] {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  width: 1.05rem !important;
  height: 1.05rem !important;
  margin: 0 !important;
  padding: 0 !important;
  appearance: none;
  -webkit-appearance: none;
  border: 1.5px solid #6b5f80 !important;
  border-radius: 50% !important;
  background: #fff !important;
  box-shadow: none !important;
  cursor: pointer;
  flex: none;
}

.fyule-grade input[type="radio"]:checked {
  border-color: var(--fyule-purple) !important;
  background-color: #fff !important;
  background-image: radial-gradient(circle, var(--fyule-purple) 0 45%, transparent 48%) !important;
  background-size: 100% 100% !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
}

.fyule-grade input[type="radio"]:focus-visible {
  outline: 2px solid var(--fyule-purple-mid);
  outline-offset: 2px;
}

.fyule-grade:has(input:checked) {
  border-color: var(--fyule-purple);
  background: linear-gradient(180deg, #fff 0%, rgba(200, 240, 0, 0.16) 100%);
  box-shadow: 0 0 0 1px rgba(74, 29, 138, 0.12), 0 8px 18px rgba(47, 15, 92, 0.1);
}

.fyule-grades-count {
  margin: 0.55rem 0 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--fyule-muted);
  text-align: right;
}

.fyule-fee {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 1.4rem 0 1.1rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(74, 29, 138, 0.08), rgba(200, 240, 0, 0.18));
  border: 1px solid var(--fyule-border);
}

.fyule-fee__label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fyule-muted);
}

.fyule-fee__amount {
  font-family: var(--fyule-font-display);
  font-size: 1.8rem;
  color: var(--fyule-purple-deep);
}

.fyule-fee p {
  margin: 0;
  max-width: 280px;
  font-size: 0.84rem;
  color: var(--fyule-muted);
  text-align: right;
}

.fyule-submit {
  width: 100%;
  border: 0;
  cursor: pointer;
  border-radius: 14px;
  padding: 1rem 1.25rem;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--fyule-purple-deep), var(--fyule-purple-mid));
  box-shadow: 0 14px 30px rgba(47, 15, 92, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.fyule-submit:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(47, 15, 92, 0.34);
}

.fyule-submit:disabled {
  opacity: 0.7;
  cursor: wait;
}

.fyule-privacy {
  margin-top: 0.85rem !important;
  text-align: center;
  font-size: 0.8rem !important;
}

.fyule-honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  height: 0;
  width: 0;
}

.fyule-footer {
  text-align: center;
  padding: 1.75rem 1rem 2.5rem;
  color: #d7c9ef;
  background: linear-gradient(180deg, transparent, var(--fyule-purple-deep));
}

.fyule-footer p {
  margin: 0.25rem 0;
  font-size: 0.88rem;
}

.fyule-footer a {
  color: var(--fyule-lime);
  text-decoration: none;
  font-weight: 600;
}

.fyule-toast-stack {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 80;
  display: grid;
  gap: 0.65rem;
  width: min(360px, calc(100vw - 2rem));
}

.fyule-toast {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--fyule-border);
  box-shadow: 0 16px 36px rgba(26, 10, 46, 0.16);
}

.fyule-toast strong {
  display: block;
  margin-bottom: 0.2rem;
}

.fyule-toast--error {
  border-color: rgba(180, 35, 24, 0.35);
}

.fyule-toast--success {
  border-color: rgba(34, 197, 94, 0.4);
}

.fyule-dialog {
  position: fixed;
  inset: 0;
  margin: auto;
  border: 0;
  padding: 0;
  border-radius: 18px;
  width: min(440px, calc(100vw - 2rem));
  max-height: min(90vh, 640px);
  overflow: auto;
  box-shadow: 0 30px 70px rgba(26, 10, 46, 0.28);
}

.fyule-dialog[open] {
  display: block;
}

.fyule-dialog::backdrop {
  background: rgba(26, 10, 46, 0.45);
}

.fyule-dialog__card {
  padding: 1.35rem;
  display: grid;
  gap: 0.55rem;
}

.fyule-dialog__card h2 {
  margin: 0;
  font-family: var(--fyule-font-display);
  color: var(--fyule-purple);
}

.fyule-dialog__actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.55rem;
  margin-top: 0.5rem;
}

.fyule-status-result {
  margin-top: 0.75rem;
  padding: 0.85rem;
  border-radius: 12px;
  background: #f3effa;
  font-size: 0.9rem;
}

@keyframes fyule-fade-up {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fyule-shimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@media (max-width: 900px) {
  .fyule-grades {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .fyule-brand {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .fyule-brand__logo {
    margin: 0 auto;
  }

  .fyule-pills {
    justify-content: center;
  }

  .fyule-grid--3 {
    grid-template-columns: 1fr;
  }

  .fyule-grades {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fyule-grade {
    min-height: 72px;
  }

  .fyule-fee {
    flex-direction: column;
    align-items: flex-start;
  }

  .fyule-fee p {
    text-align: left;
    max-width: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .fyule-brand,
  .fyule-brochure-bar,
  .fyule-form-card,
  .fyule-brochure-btn,
  .fyule-submit {
    animation: none !important;
    transition: none !important;
  }
}

