@charset "utf-8";

/* 沖縄の宿泊税 かんたん計算
   色：琉球藍・珊瑚・月桃の黄・砂の色。柄：八重山ミンサーの「五つと四つ」。
   外部フォント・外部リソースは読み込まない。 */

:root {
  --ai: #1E3A5A;            /* 琉球藍。白文字で 11.6:1 */
  --ai-deep: #142A42;
  --ai-soft: #E7EDF3;
  --sango: #C9553D;         /* 珊瑚。大きな数字に使う（白地で 4.6:1） */
  --sango-ink: #A8432E;     /* 珊瑚の文字色（白地で 6.0:1） */
  --sango-soft: #FBEDE7;
  --getto: #E8B547;         /* 月桃の黄。飾りだけに使う */
  --getto-soft: #FDF4DD;
  --sand: #F8F3E9;
  --shell: #FFFDF8;
  --ink: #1E2B33;
  --ink-soft: #4E5D66;      /* sand 上で 6.6:1 */
  --line: #E6DCCB;
  --line-strong: #CDBFA6;
  --err: #8A2F22;
  --err-bg: #FBEDEA;

  --radius: 16px;
  --font: "BIZ UDPGothic", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", YuGothic, "Noto Sans JP", Meiryo, system-ui, sans-serif;
  --shadow: 0 1px 2px rgba(30, 58, 90, .06), 0 10px 28px rgba(30, 58, 90, .08);

  /* ミンサー柄（五つ玉と四つ玉、両端のムカデの足） */
  --minsa: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='108' height='24' viewBox='0 0 108 24'%3E%3Crect width='108' height='24' fill='%231E3A5A'/%3E%3Cpath d='M0 3H108M0 21H108' stroke='%23E8B547' stroke-width='1'/%3E%3Cpath d='M0 5.5H108M0 18.5H108' stroke='%23E8B547' stroke-width='3' stroke-dasharray='1.5 4.5'/%3E%3Cg fill='%23F8F3E9'%3E%3Crect x='6' y='9' width='6' height='6'/%3E%3Crect x='15' y='9' width='6' height='6'/%3E%3Crect x='24' y='9' width='6' height='6'/%3E%3Crect x='33' y='9' width='6' height='6'/%3E%3Crect x='42' y='9' width='6' height='6'/%3E%3Crect x='60' y='9' width='6' height='6'/%3E%3Crect x='69' y='9' width='6' height='6'/%3E%3Crect x='78' y='9' width='6' height='6'/%3E%3Crect x='87' y='9' width='6' height='6'/%3E%3C/g%3E%3Crect x='51' y='11' width='6' height='2' fill='%23C9553D'/%3E%3Crect x='96' y='11' width='9' height='2' fill='%23C9553D'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.8;
  letter-spacing: .02em;
  font-feature-settings: "palt" 1;
  overflow-wrap: anywhere;
  line-break: strict;
}

h1, h2, h3 { margin: 0; line-height: 1.4; font-weight: 700; }
p { margin: 0; }
a { color: var(--ai); text-underline-offset: 3px; }
a:hover { color: var(--sango-ink); }
ul, ol { margin: 0; }

.wrap { width: min(1040px, 100%); margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 32px; } }

.skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 10;
  background: var(--ai); color: #fff; padding: 8px 14px; border-radius: 8px;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--getto); outline-offset: 2px; }

.em { color: var(--sango-ink); font-weight: 700; }
.br-sp { display: inline; }
@media (min-width: 768px) { .br-sp { display: none; } }

/* ---------- ミンサー柄の帯 ---------- */

.minsa {
  height: 24px;
  background-image: var(--minsa);
  background-repeat: repeat-x;
  background-size: auto 24px;
}
.minsa--thin { height: 12px; background-size: auto 12px; }

/* ---------- 見出し（藍の帯） ---------- */

.hero { background: var(--ai); color: #fff; }
.hero__inner { padding-top: 28px; padding-bottom: 36px; }
.hero__eyebrow {
  display: inline-block;
  font-size: 13px; letter-spacing: .14em;
  color: var(--ai-deep); background: var(--getto);
  border-radius: 999px; padding: 2px 14px;
  font-weight: 700;
}
.hero__title { font-size: 34px; margin-top: 14px; letter-spacing: .04em; }
.hero__lead { margin-top: 12px; color: #DCE5EE; max-width: 40em; font-size: 15px; }
@media (min-width: 768px) {
  .hero__inner { padding-top: 48px; padding-bottom: 56px; }
  .hero__title { font-size: 48px; }
  .hero__lead { font-size: 16px; }
}

/* ---------- ポイント3つ ---------- */

.points {
  display: grid; gap: 10px;
  margin-top: 18px;
}
@media (min-width: 768px) { .points { grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 24px; } }
.point {
  background: var(--shell);
  border: 1px solid var(--line);
  border-top: 4px solid var(--sango);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 12px 16px;
  display: grid; grid-template-columns: 4.5em 1fr; align-items: center; gap: 8px;
}
@media (min-width: 768px) { .point { grid-template-columns: 1fr; padding: 16px 20px; } }
.point__label {
  font-size: 13px; font-weight: 700; color: var(--ai);
  background: var(--ai-soft); border-radius: 6px; text-align: center; padding: 2px 6px;
  justify-self: start;
}
.point__value { font-size: 16px; font-weight: 700; line-height: 1.5; }
.point__value small { display: block; font-size: 12.5px; color: var(--ink-soft); font-weight: 400; }

/* ---------- カード ---------- */

main.wrap { display: grid; gap: 20px; margin-top: 20px; }

.card {
  background: var(--shell);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 16px;
  min-width: 0;
}
@media (min-width: 768px) { .card { padding: 30px 32px; } }
.card--quiet { background: #FBF8F1; box-shadow: none; }
.card__title {
  font-size: 20px;
  padding-left: 14px;
  border-left: 5px solid var(--ai);
  margin-bottom: 16px;
}
@media (min-width: 768px) { .card__title { font-size: 23px; } }
.card__lead { color: var(--ink-soft); font-size: 15px; margin-bottom: 14px; }
.card__note { margin-top: 12px; font-size: 13px; color: var(--ink-soft); }

/* ---------- タブ ---------- */

.tabs {
  display: grid; grid-template-columns: 1fr 1fr; gap: 6px;
  background: var(--ai-soft); border-radius: 14px; padding: 6px;
  margin-bottom: 20px;
}
.tab {
  font: inherit; color: var(--ai); cursor: pointer;
  border: 0; border-radius: 10px; background: transparent;
  padding: 10px 8px; min-height: 56px;
  display: grid; align-content: center; justify-items: center; gap: 0;
}
.tab__main { font-weight: 700; font-size: 15px; line-height: 1.4; }
.tab__sub { font-size: 12px; color: var(--ink-soft); line-height: 1.4; }
.tab[aria-selected="true"] { background: var(--ai); color: #fff; box-shadow: 0 2px 6px rgba(30, 58, 90, .25); }
.tab[aria-selected="true"] .tab__sub { color: #DCE5EE; }

/* ---------- 入力 ---------- */

.form { display: grid; gap: 18px; }

.step-field { display: grid; gap: 8px; }
@media (min-width: 640px) { .step-field { grid-template-columns: 84px 1fr; gap: 16px; align-items: start; } }
.step-badge {
  justify-self: start;
  font-size: 12px; font-weight: 700; letter-spacing: .08em;
  color: #fff; background: var(--ai);
  border-radius: 999px; padding: 3px 12px;
  white-space: nowrap;
}
@media (min-width: 640px) { .step-badge { margin-top: 2px; } }

.field-group { display: grid; gap: 16px; min-width: 0; }
.field { border: 0; margin: 0; padding: 0; min-width: 0; display: grid; gap: 6px; }
.field__label { font-weight: 700; font-size: 15px; padding: 0; }
.field__hint { font-size: 13px; color: var(--ink-soft); line-height: 1.7; }
.field__error { font-size: 13.5px; color: var(--err); background: var(--err-bg); border-radius: 8px; padding: 6px 10px; }

select,
input[type="text"],
input[type="date"] {
  width: 100%; min-height: 50px;
  font: inherit; font-size: 17px; color: var(--ink);
  background: #fff;
  border: 1.5px solid var(--line-strong);
  border-radius: 10px;
  padding: 10px 12px;
}
select:focus, input:focus { border-color: var(--ai); }
[aria-invalid="true"] { border-color: var(--err) !important; }

.money { position: relative; }
.money input { padding-right: 44px; text-align: right; font-variant-numeric: tabular-nums; font-size: 22px; font-weight: 700; }
.money__unit { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-soft); pointer-events: none; }

.choices { display: grid; gap: 10px; }
@media (min-width: 520px) { .choices { grid-template-columns: 1fr 1fr; } }
.choice {
  display: flex; gap: 10px; align-items: flex-start;
  border: 1.5px solid var(--line-strong); border-radius: 10px;
  padding: 12px 14px; cursor: pointer; background: #fff;
}
.choice:has(input:checked) { border-color: var(--ai); background: var(--ai-soft); }
.choice input { margin-top: 5px; width: 18px; height: 18px; accent-color: var(--ai); flex: none; }
.choice span { display: grid; line-height: 1.5; }
.choice small { color: var(--ink-soft); font-size: 12.5px; }

.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; cursor: pointer; }
.check input { margin-top: 5px; width: 18px; height: 18px; flex: none; accent-color: var(--ai); }

.grid-2 { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
@media (max-width: 359px) { .grid-2 { grid-template-columns: 1fr; } }

/* ---------- 答え ---------- */

.answer {
  margin-top: 22px;
  border-radius: 14px;
  background: var(--sango-soft);
  border: 1.5px solid #F0CDBF;
  padding: 18px 12px;
}
@media (min-width: 768px) { .answer { padding: 22px 26px; } }
.answer__label { font-size: 14px; font-weight: 700; color: var(--sango-ink); }
.answer__total {
  font-size: 46px; line-height: 1.15; font-weight: 700;
  color: var(--sango); font-variant-numeric: tabular-nums;
  margin: 4px 0 8px;
}
.answer__total small { font-size: 18px; margin-left: 4px; }
.answer__formula { font-size: 15.5px; font-weight: 700; }
.answer__note {
  margin-top: 8px; font-size: 13.5px; color: var(--ink-soft);
  padding-left: 10px; border-left: 3px solid #E8B9A8;
}
.answer__errors { margin-top: 6px; padding-left: 1.2em; color: var(--err); font-size: 14px; }

/* 計算の流れ（料金 → 切り捨て → ×2% → 税額） */
.calc-flow {
  display: grid; gap: 6px; margin-top: 14px;
  grid-template-columns: 1fr;
}
@media (min-width: 560px) { .calc-flow { grid-template-columns: 1fr auto 1fr auto 1fr; align-items: stretch; } }
.calc-flow__box {
  background: #fff; border: 1px solid #EBD3C8; border-radius: 10px;
  padding: 8px 12px; text-align: center;
}
.calc-flow__box small { display: block; font-size: 12px; color: var(--ink-soft); }
.calc-flow__box strong { font-size: 18px; font-variant-numeric: tabular-nums; }
.calc-flow__box--result { background: var(--sango); border-color: var(--sango); color: #fff; }
.calc-flow__box--result small { color: #FBE3DB; }
.calc-flow__arrow {
  font-size: 12px; color: var(--sango-ink); font-weight: 700;
  display: grid; place-items: center; text-align: center; line-height: 1.3;
}
.calc-flow__arrow::after { content: "↓"; display: block; font-size: 15px; }
@media (min-width: 560px) { .calc-flow__arrow::after { content: "→"; } }

.parts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0 0; }
.parts > div { background: #fff; border: 1px solid #EBD3C8; border-radius: 10px; padding: 8px 12px; }
.parts dt { font-size: 12.5px; color: var(--ink-soft); }
.parts dd { margin: 0; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }

.detail { margin-top: 16px; border-top: 1px dashed #E8B9A8; padding-top: 10px; }
.detail summary { cursor: pointer; font-weight: 700; font-size: 14.5px; padding: 6px 0; color: var(--ai); }
.answer__sub { font-size: 15px; margin: 18px 0 8px; }

.answer__actions { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btn {
  min-height: 44px; padding: 10px 18px; border-radius: 999px;
  border: 1.5px solid var(--ai); background: #fff; color: var(--ai);
  font: inherit; font-size: 14.5px; font-weight: 700; cursor: pointer;
}
.btn:hover { background: var(--ai); color: #fff; }
.copy-status { font-size: 13px; color: var(--ink-soft); }

/* ---------- 表 ---------- */

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.table th, .table td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
.table th[scope="row"], .table thead th:first-child { text-align: left; }
.table thead th { background: var(--ai); color: #fff; font-weight: 700; font-size: 13px; vertical-align: bottom; }
.table tbody tr:last-child > * { border-bottom: 0; }
.table tbody tr:nth-child(even) { background: #FBF8F1; }
.table .is-exempt { color: var(--ink-soft); }
.table--wide { min-width: 540px; }
.table--compact th, .table--compact td { padding: 9px 6px; font-size: 12.5px; }
.table--compact thead th { white-space: normal; }
.th-sub { display: block; font-size: 11px; font-weight: 400; color: #C9D6E3; }
.td-sub { display: block; font-size: 11.5px; color: var(--ink-soft); font-weight: 400; }
.td-total { font-weight: 700; color: var(--sango-ink); }
.td-parts span { display: block; font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); }
.quick-table tr.is-cap { background: var(--getto-soft); }
@media (max-width: 479px) {
  .quick-table th, .quick-table td { padding: 9px 8px; font-size: 13px; }
}

/* ---------- 入るもの・入らないもの ---------- */

.compare { display: grid; gap: 12px; }
@media (min-width: 640px) { .compare { grid-template-columns: 1fr 1fr; gap: 16px; } }
.compare__col { border-radius: 12px; padding: 14px 16px 16px; border: 1.5px solid; }
.compare__col--in { border-color: #B9CBDD; background: var(--ai-soft); }
.compare__col--out { border-color: #EBC9BC; background: var(--sango-soft); }
.compare__head { font-size: 16px; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.compare__head::before {
  content: ""; width: 22px; height: 22px; border-radius: 50%; flex: none;
  display: inline-block;
}
.compare__col--in .compare__head { color: var(--ai); }
.compare__col--in .compare__head::before { border: 4px solid var(--ai); }
.compare__col--out .compare__head { color: var(--sango-ink); }
.compare__col--out .compare__head::before {
  background:
    linear-gradient(45deg, transparent 43%, var(--sango-ink) 43%, var(--sango-ink) 57%, transparent 57%),
    linear-gradient(-45deg, transparent 43%, var(--sango-ink) 43%, var(--sango-ink) 57%, transparent 57%);
  border-radius: 0;
}
.compare ul { padding-left: 1.2em; display: grid; gap: 4px; font-size: 15px; }

/* ---------- 手続き3ステップ ---------- */

.flow { list-style: none; padding: 0; display: grid; gap: 0; }
.flow__step { display: grid; gap: 10px; position: relative; padding-bottom: 26px; }
.flow__step:last-child { padding-bottom: 0; }
@media (min-width: 640px) { .flow__step { grid-template-columns: 170px 1fr; gap: 18px; } }
.flow__step:not(:last-child)::after {
  content: ""; position: absolute; left: 50%; bottom: 4px; transform: translateX(-50%);
  border: 11px solid transparent; border-top: 12px solid var(--getto); border-bottom: 0;
}
@media (min-width: 640px) { .flow__step:not(:last-child)::after { left: 85px; } }
.flow__badge {
  background: var(--ai); color: #fff; border-radius: 14px;
  padding: 12px 14px; display: grid; align-content: center; gap: 0;
}
.flow__badge span { font-size: 12px; letter-spacing: .1em; color: var(--getto); font-weight: 700; }
.flow__badge strong { font-size: 20px; line-height: 1.4; }
.flow__badge small { font-size: 12px; color: #DCE5EE; }
.flow__body { background: #FBF8F1; border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; display: grid; gap: 6px; font-size: 15px; }
.flow__body ul { padding-left: 1.2em; display: grid; gap: 4px; }
.flow__note { font-size: 13.5px; color: var(--ink-soft); }

/* ---------- こんなときは？ ---------- */

.faq { display: grid; gap: 8px; }
.faq details { border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.faq summary {
  cursor: pointer; list-style: none; font-weight: 700; padding: 12px 44px 12px 16px; position: relative;
  min-height: 48px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "Q"; color: var(--sango-ink); margin-right: 8px; }
.faq summary::after {
  content: "+"; position: absolute; right: 16px; top: 50%; transform: translateY(-50%);
  font-size: 20px; color: var(--ai);
}
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 16px 14px 36px; font-size: 15px; color: var(--ink); }

/* ---------- 注意・問い合わせ ---------- */

.notes__list { padding-left: 1.2em; display: grid; gap: 8px; font-size: 14.5px; }
.contact { margin: 14px 0 0; display: grid; gap: 6px; font-size: 14.5px; }
.contact div { display: grid; grid-template-columns: 7.5em 1fr; gap: 8px; }
.contact dt { color: var(--ink-soft); }
.contact dd { margin: 0; font-weight: 700; }
.notes__source { margin-top: 14px; font-size: 13px; color: var(--ink-soft); }

/* ---------- 足元 ---------- */

.foot { margin-top: 36px; background: var(--ai); color: #DCE5EE; font-size: 13px; }
.foot__inner { padding-top: 20px; padding-bottom: 36px; }
.foot__maker { margin-top: 4px; color: #fff; }
.noscript { padding: 16px; }

/* ---------- 埋め込み（?embed=1） ---------- */

.is-embed .hero,
.is-embed .points,
.is-embed .foot,
.is-embed .skip-link { display: none; }
.is-embed main.wrap { margin-top: 12px; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
