 :root {
  --page-bg: #f3f8fc;
  --card: #ffffff;
  --text: #071936;
  --muted: #607086;
  --blue: #0b75c9;
  --blue-2: #2ba8ff;
  --blue-soft: #eaf7ff;
  --line: rgba(7, 25, 54, 0.08);
  --shadow: 0 12px 30px rgba(19, 57, 92, 0.12);
  --shadow-soft: 0 6px 18px rgba(19, 57, 92, 0.10);
  --radius: 18px;
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  background: var(--page-bg);
}

body {
  min-height: 100%;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 16% 4%, rgba(255,255,255,.9), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, #f3f8fc 34%, #edf4fa 100%);
}

a { color: inherit; }

.brand-link {
  color: inherit;
  text-decoration: none;
}

.brand-link:focus-visible,
.footer a:focus-visible {
  outline: 3px solid rgba(43,168,255,.45);
  outline-offset: 4px;
  border-radius: 8px;
}

.site-shell {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 0 0 26px;
}

.hero {
  position: relative;
  overflow: hidden;
}

.hero-image {
  display: block;
  width: 100%;
  height: clamp(165px, 40vw, 235px);
  object-fit: cover;
  object-position: center 66%;
  border-bottom-left-radius: 30px;
  border-bottom-right-radius: 30px;
  box-shadow: 0 14px 38px rgba(4, 45, 83, 0.15);
}

.hero-content {
  text-align: center;
  padding: 22px 18px 14px;
}

.hero h1 {
  margin: 0;
  color: #10254b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.15rem, 9vw, 3.35rem);
  line-height: 1;
  letter-spacing: -0.055em;
  font-weight: 500;
}

.hero p {
  margin: 10px 0 0;
  color: #43536a;
  font-size: clamp(.98rem, 3.6vw, 1.1rem);
  font-weight: 600;
}

.hero p span {
  color: var(--blue);
  padding: 0 7px;
}

.links-section {
  padding: 0 12px;
}

.link-list {
  display: grid;
  gap: 10px;
}

.link-card {
  position: relative;
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 82px;
  padding: 11px 10px;
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  background: rgba(255,255,255,.94);
  border: 1px solid rgba(255,255,255,.88);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.link-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255,255,255,.6), transparent 42%);
}

.link-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: rgba(11,117,201,.22);
}

.link-card:active {
  transform: translateY(0) scale(.995);
}

.link-card.has-actions {
  cursor: default;
  grid-template-columns: 68px minmax(0, 1fr);
}

.link-card.has-actions:hover {
  transform: none;
}

.link-card.featured {
  grid-template-columns: 78px minmax(0, 1fr) auto;
  min-height: 116px;
  margin-bottom: 8px;
  padding: 15px 12px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.98), rgba(231,247,255,.96)),
    var(--card);
  border: 1.5px solid rgba(43,168,255,.88);
  box-shadow: 0 16px 40px rgba(13, 112, 196, .18);
}

.thumbnail-wrap,
.link-content,
.side-actions { position: relative; z-index: 1; }

.thumbnail-wrap {
  width: 68px;
  height: 52px;
  border-radius: 13px;
  overflow: hidden;
  background: #eaf7ff;
  box-shadow: 0 4px 12px rgba(12, 50, 83, .11);
  flex-shrink: 0;
}

.featured .thumbnail-wrap {
  width: 78px;
  height: 78px;
  border-radius: 15px;
  box-shadow: 0 8px 20px rgba(12, 50, 83, .18);
}

.thumbnail {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.link-content {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.link-content h2 {
  margin: 0;
  font-size: .985rem;
  line-height: 1.18;
  letter-spacing: -.02em;
  font-weight: 760;
}

.featured .link-content h2 {
  color: #0d2752;
  font-size: 1.08rem;
  line-height: 1.18;
  font-weight: 850;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 9px;
  min-height: 26px;
  padding: 0 11px;
  border-radius: 7px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), #075aa3);
  font-size: .74rem;
  font-weight: 850;
  letter-spacing: .055em;
}

.mini-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  min-height: 22px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 850;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.mini-tag.free {
  color: #0e6d2f;
  background: #eaf9ef;
  border: 1px solid rgba(14, 109, 47, 0.10);
}

.note {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.2;
}

.inline-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  width: 100%;
  margin-top: 11px;
}

.action-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border-radius: 999px;
  padding: 9px 13px;
  border: 1px solid transparent;
  font: inherit;
  font-size: .82rem;
  font-weight: 850;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: transform 150ms ease, filter 150ms ease, box-shadow 150ms ease;
}

.action-btn:hover {
  transform: translateY(-1px);
  filter: brightness(.98);
}

.action-btn.primary {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 8px 16px rgba(11,117,201,.20);
}

.action-btn.secondary {
  color: var(--blue);
  background: #fff;
  border-color: rgba(11,117,201,.25);
  box-shadow: 0 6px 14px rgba(7,25,54,.07);
}

.side-actions {
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  justify-content: center;
}

.arrow {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--blue);
  background: rgba(255,255,255,.82);
  border: 1px solid rgba(7,25,54,.06);
  box-shadow: 0 5px 12px rgba(7,25,54,.08);
  font-size: 1.8rem;
  font-weight: 550;
  line-height: 1;
}

.featured .arrow {
  width: 38px;
  height: 38px;
  background: rgba(255,255,255,.9);
}

.copy-btn {
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: 6px 9px;
  color: #fff;
  background: var(--blue);
  font: inherit;
  font-size: .68rem;
  font-weight: 850;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(11,117,201,.18);
}

.copy-btn:hover { filter: brightness(.96); }

.link-card.disabled {
  opacity: .78;
  cursor: not-allowed;
}

.link-card.disabled .arrow {
  color: #8a99aa;
}

.footer {
  padding: 22px 16px 0;
  color: #75859a;
  font-size: .82rem;
  text-align: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom));
  transform: translate(-50%, 18px);
  padding: 11px 16px;
  border-radius: 999px;
  color: #fff;
  background: rgba(7, 25, 54, .94);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
  font-weight: 750;
  z-index: 5;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 380px) {
  .links-section { padding-inline: 8px; }

  .hero-image {
    border-bottom-left-radius: 24px;
    border-bottom-right-radius: 24px;
  }

  .link-card {
    grid-template-columns: 58px minmax(0, 1fr) auto;
    gap: 10px;
    min-height: 78px;
    padding: 10px 8px;
  }

  .link-card.featured {
    grid-template-columns: 66px minmax(0, 1fr) auto;
    min-height: 108px;
    padding: 12px 9px;
  }

  .link-card.has-actions {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .thumbnail-wrap {
    width: 58px;
    height: 48px;
  }

  .featured .thumbnail-wrap {
    width: 66px;
    height: 66px;
  }

  .link-content h2 { font-size: .92rem; }
  .featured .link-content h2 { font-size: .98rem; }
  .copy-btn { display: none; }
  .action-btn { font-size: .76rem; min-height: 36px; }
  .arrow { width: 30px; height: 30px; }
}

@media (min-width: 760px) {
  .site-shell {
    padding-top: 22px;
    padding-bottom: 42px;
  }

  .hero-image {
    border-radius: 32px;
  }

  .links-section {
    padding-inline: 18px;
  }

  .link-card {
    min-height: 92px;
  }

  .link-card.featured {
    min-height: 126px;
  }
}

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

.bio-line {
  width: min(92%, 560px);
  margin: 9px auto 0;
  color: #58708a;
  font-size: clamp(.78rem, 3.1vw, .92rem);
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: -.005em;
}

.card-lines {
  display: grid;
  gap: 3px;
  margin-top: 6px;
}
.card-line {
  margin: 0;
  color: var(--muted);
  font-size: .76rem;
  line-height: 1.2;
  font-weight: 620;
  letter-spacing: -.01em;
}

.link-card[data-link-id="japan-visa-docs"] {
  min-height: 106px;
}

@media (max-width: 380px) {
  .card-line { font-size: .71rem; }
  .link-card[data-link-id="japan-visa-docs"] { min-height: 116px; }
}
