* { box-sizing: border-box; }
:root { font-family: "Manrope", system-ui, sans-serif; color: #17211b; background: #edf4ee; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at top, #f9fcf8 0, #edf4ee 38%, #e7efe8 100%); }
button, input { font: inherit; }
button { cursor: pointer; }
.page { width: min(100%, 760px); margin: 0 auto; padding: 32px 16px 56px; }
.card { background: #fff; border: 1px solid #dce7de; border-radius: 28px; padding: 28px; box-shadow: 0 20px 60px rgba(34, 62, 43, .09); }
.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 34px; }
.brand-logo { width: 156px; height: auto; display: block; object-fit: contain; }
.brand-subtitle { color: #728078; font-size: 12px; margin-left: auto; }
.eyebrow { color: #167446; letter-spacing: .14em; font-size: 12px; font-weight: 800; margin: 0 0 8px; }
h1 { font-size: clamp(30px, 7vw, 50px); line-height: 1.05; letter-spacing: -.04em; margin: 0; max-width: 620px; }
h2 { margin: 0; font-size: 22px; }
.intro { color: #647269; line-height: 1.7; margin: 16px 0 22px; max-width: 620px; }
.mode-banner { margin: -6px 0 22px; border: 1px solid #f0d79b; border-radius: 14px; padding: 12px 14px; background: #fff8e8; color: #765a1d; font-size: 13px; line-height: 1.5; }
.rule-card { display: flex; justify-content: space-between; gap: 16px; align-items: center; border-radius: 18px; padding: 18px; background: #edf8f1; border: 1px solid #d6ecdd; margin-bottom: 26px; }
.rule-card strong, .rule-card span { display: block; }
.rule-card span { color: #627269; font-size: 13px; text-align: right; }
form { display: grid; gap: 18px; }
label, legend { font-size: 14px; font-weight: 700; color: #263229; }
label small { display: block; margin-top: 7px; color: #7d8981; font-weight: 500; line-height: 1.4; }
input[type="text"], input[type="tel"], input:not([type]) { width: 100%; }
input { border: 1px solid #cbd8ce; border-radius: 14px; padding: 14px 15px; outline: none; margin-top: 8px; background: #fff; }
input:focus { border-color: #167446; box-shadow: 0 0 0 3px rgba(22, 116, 70, .09); }
.phone-input { display: flex; margin-top: 8px; border: 1px solid #cbd8ce; border-radius: 14px; overflow: hidden; }
.phone-input:focus-within { border-color: #167446; box-shadow: 0 0 0 3px rgba(22, 116, 70, .09); }
.phone-input .prefix { display: flex; align-items: center; padding: 0 14px; background: #f3f7f4; border-right: 1px solid #d9e4db; color: #45534a; font-weight: 700; }
.phone-input input { border: 0; margin: 0; border-radius: 0; box-shadow: none; }
.reference-input { display: flex; margin-top: 8px; border: 1px solid #cbd8ce; border-radius: 14px; overflow: hidden; }
.reference-input:focus-within { border-color: #167446; box-shadow: 0 0 0 3px rgba(22, 116, 70, .09); }
.reference-input .prefix { display: flex; align-items: center; padding: 0 14px; background: #f3f7f4; border-right: 1px solid #d9e4db; color: #45534a; font-weight: 800; letter-spacing: .04em; }
.reference-input input { flex: 1; border: 0; margin: 0; border-radius: 0; box-shadow: none; }
fieldset { border: 0; padding: 0; margin: 0; }
.source-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.radio-card { display: flex; align-items: flex-start; gap: 10px; border: 1px solid #cbd8ce; border-radius: 14px; padding: 14px; cursor: pointer; }
.radio-card:has(input:checked) { border-color: #167446; background: #f2faf5; }
.radio-card input { margin: 3px 0 0; padding: 0; }
.radio-card strong, .radio-card small { display: block; }
.radio-card small { color: #718078; font-size: 12px; margin-top: 3px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; line-height: 1.5; color: #5a675f; }
.consent input { margin: 4px 0 0; }
button { border: 0; border-radius: 14px; padding: 14px 18px; background: #167446; color: white; font-weight: 800; }
button:disabled { opacity: .55; cursor: wait; }
button.secondary { background: #eff6f1; color: #1a6d46; border: 1px solid #d4e6d9; }
.text-button { background: transparent; color: #167446; padding: 6px 0; }
.message { min-height: 20px; margin-top: 14px; color: #b54040; font-size: 14px; line-height: 1.5; }
.message.success { color: #167446; }
.result, .all-entries { margin-top: 20px; border-radius: 22px; border: 1px solid #d9e6dc; padding: 20px; background: #fbfdfb; }
.result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
.result-grid > div { border-radius: 14px; background: #eef7f1; padding: 14px; }
.result-grid .wide { grid-column: 1 / -1; }
.result-grid span, .result-grid strong { display: block; }
.result-grid span { font-size: 12px; color: #708078; }
.result-grid strong { margin-top: 5px; font-size: 22px; }
.result-label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 9px; }
.entry-list { display: grid; gap: 8px; }
.entry-code { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; background: white; border: 1px dashed #b9ccbE; border-radius: 12px; font-weight: 800; letter-spacing: .06em; }
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.fineprint, .footer-note { color: #7b8880; font-size: 12px; line-height: 1.5; }
.existing-access { display: flex; justify-content: space-between; align-items: center; gap: 14px; border-radius: 18px; border: 1px solid #d5e7da; background: #f3faf5; padding: 14px; margin-bottom: 22px; }
.existing-access strong, .existing-access span { display: block; }
.existing-access span { color: #6e7c73; font-size: 12px; margin-top: 3px; }
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.hidden { display: none !important; }

@media (max-width: 620px) {
  .page { padding: 12px 10px 40px; }
  .card { padding: 20px; border-radius: 22px; }
  .rule-card { align-items: flex-start; flex-direction: column; }
  .rule-card span { text-align: left; }
  .source-options, .result-actions { grid-template-columns: 1fr; }
  .existing-access { align-items: stretch; flex-direction: column; }
}
