.find-panel {
  --find-paper: #f1ebdd;
  --find-muted: #aeb9ce;
  --find-gold: #d4b277;
  --find-line: #3a4767;
  min-width: 0;
  padding-bottom: 22px;
  word-break: keep-all;
  overflow-wrap: break-word;
}

.find-card, .find-pair-panel, .find-landing {
  border: 1px solid #3a4767;
  border-radius: 22px;
  background: linear-gradient(160deg, #1c2740, #131c30);
}

.find-card, .find-pair-panel {
  padding: 18px 15px;
}

body:has(#find-maker:not([hidden])) .site-header { display: none }
.find-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 44px;
  border-bottom: 1px solid #2a3552;
  color: var(--find-paper);
}
.fate-logo {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #f1ebdd;
  font: 800 18px/1.75 var(--serif);
  letter-spacing: .02em;
}
.fate-logo::before {
  content: '';
  flex: 0 0 9px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #d65a62;
  box-shadow: 0 0 12px #d65a62;
}
.find-brand small { color: var(--find-muted) }

.find-pair-panel { margin-top: 20px }
.find-pair-panel #pair-panel { margin: 0; padding: 0; border: 0 }
.find-pair-panel #pair-art { border-radius: 14px }
.find-pair-panel #pair-id { font-weight: 700 }

.find-panel h1 {
  margin: 0 0 6px;
  font: 800 clamp(1.55rem, 6vw, 2rem)/1.35 var(--serif);
  color: var(--find-paper);
}

.find-panel .find-sub {
  margin: 5px 0 14px;
  color: var(--find-muted);
  font-size: .875rem;
}

.find-panel .find-back {
  margin-bottom: 8px;
  padding-inline: 0;
  border: 0;
  background: transparent;
  color: #e7cc95;
}

.find-pair-button {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2px .4em;
  width: 100%;
  min-height: 50px;
  margin-top: 14px;
  background: linear-gradient(135deg, #e7cd96, #c9a660);
  color: #251c15;
  border: 0;
  border-radius: 14px;
  font-weight: 800;
}

.find-pair-button small { font-size: .76em; font-weight: 500 }
.find-panel .btn { min-height: 44px }
.find-panel :focus-visible, .find-pair-button:focus-visible { outline: 2px solid #fae1ad; outline-offset: 3px }
.find-panel h1:focus { outline: 0 }

.find-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.find-range {
  margin-block: 16px 20px;
  padding: 12px;
  border: 1px solid #a85768;
  border-radius: 15px;
  background: #211f32;
}

.find-range h2 {
  margin: 0 0 8px;
  color: #f3919b;
  font: 800 1rem/1.4 var(--sans);
}

.find-range-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px auto 44px;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  color: var(--find-paper);
  font: 700 .9rem/1.35 var(--sans);
}

.find-range-row .btn {
  min-width: 44px;
  padding: 0;
  border: 1px solid var(--find-line);
  border-radius: 10px;
  background: #171c2c;
  color: var(--find-paper);
  font: 700 1.2rem/1 var(--sans);
}

.find-range-row .btn:disabled { color: #82899b; border-color: #34394c; background: #222333; cursor: default }
.find-range-row span[id] { min-width: 2.25em; text-align: center; font-variant-numeric: tabular-nums }
#find-range-summary { margin: 11px 0 0; color: var(--find-muted); font: .83rem/1.55 var(--sans) }
#find-range-summary span { display: inline-block; max-width: 100% }
.find-story-note { margin: 0 0 10px; color: var(--find-gold); text-align: center; font: 700 .86rem/1.45 var(--sans) }
.find-primary-actions { margin-top: 12px }
.find-primary-actions .btn { padding-inline: 4px }

.find-frame {
  display: grid;
  place-items: center;
  padding: clamp(10px, 3.25vw, 15px);
  border: 1px solid #293653;
  border-radius: 16px;
  background: #080d18;
}

.find-preview {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 520px;
  border-radius: 10px;
  box-shadow: 0 8px 20px #0008;
}

.find-actions .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--find-line);
  border-radius: 13px;
  background: #1a2439;
  color: var(--find-paper);
  text-align: center;
  text-decoration: none;
  font: 700 .86rem/1.35 var(--sans);
}

.find-wide { grid-column: 1 / -1 }

#find-instagram {
  color: #fff;
  border: 0;
  background: linear-gradient(145deg, #b24455, #932f45);
}

.find-threads-mark { font: 800 .83em/1 var(--sans) }
#find-threads { background: #f1ebdd; color: #211d1b; border-color: #f1ebdd }
#find-threads:not([href]), .find-actions button:disabled { opacity: .55; pointer-events: none }
#find-status:empty, #find-landing-result:empty { display: none }
#find-status, .find-actions + .find-sub { margin-top: 12px }

.find-copy-box, #find-birthday {
  display: block;
  width: 100%;
  min-width: 0;
  font: inherit;
  color: inherit;
  background: #0f1729;
  border: 1px solid var(--find-line);
  border-radius: 12px;
  padding: 10px 12px;
}

.find-copy-box {
  field-sizing: content;
  min-height: 6rem;
  resize: vertical;
  font-size: .83rem;
  overflow-wrap: break-word;
  word-break: normal;
}

.find-landing { overflow: hidden; padding: 0 }
.find-landing-top { padding: 18px 15px 16px; background: radial-gradient(130% 85% at 50% 0, #2c233c, #151d30 74%) }
.find-panel #find-landing-title {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  border: 1px solid #f19bac45;
  border-radius: 999px;
  padding: 4px 9px;
  background: #a9556740;
  color: #ffc0cb;
  font: 800 .79rem/1.4 var(--sans);
}
#find-examples h2 { margin: 5px 0 11px; color: #f1ebdd; font: 800 clamp(1.2rem, 5vw, 1.5rem)/1.42 var(--serif) }
.find-landing-body { padding: 14px 15px 18px }
.find-target { display: flex; align-items: center; gap: 10px; margin-top: 13px }
.find-target .find-sub { margin: 0 }
#find-target-art { display: block; flex: 0 0 54px; border: 1px solid var(--find-gold); border-radius: 50%; object-fit: contain; background: #faeee4 }
.find-example-list { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0 }
#find-maker-dates { margin: 17px 0 16px }
.find-example-list li {
  padding: .37em .6em;
  border: 1px solid #d4b27755;
  border-radius: 99px;
  background: #d4b2770e;
  color: #ead7ac;
  font: 700 .82rem/1.25 var(--serif);
}
#find-check { display: grid; gap: 7px }
#find-check label { color: var(--find-muted); font-size: .86rem }
#find-birthday { min-height: 48px; padding-inline: 9px }
#find-landing-result {
  margin: 12px 0 0;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--find-line);
  background: #0f1729;
  color: var(--find-paper);
  font-size: .92rem;
}
#find-landing-result.is-match { border-color: var(--find-gold); background: linear-gradient(135deg, #302819, #151d30); color: #ffebc3 }

@media (max-width: 350px) {
  .find-card, .find-pair-panel, .find-landing-top, .find-landing-body { padding-inline: 12px }
  #find-threads {
    gap: 4px;
    padding-inline: 4px;
    font-size: .82rem;
    white-space: nowrap;
  }
}
