/* Pulsar Innovations — shared styles (plain CSS, no build step) */

:root {
  --white: #ffffff;
  --black: #111418;
  --navy: #0b2545;
  --navy-deep: #071a33;
  --teal: #01d5dd;          /* sampled from the Pulsar logo — see README */
  --teal-ink: #007a80;      /* darker teal for text/links on white (AA contrast) */
  --grey-50: #f5f7fa;
  --grey-100: #e8edf3;
  --grey-500: #5a6472;
  --grey-700: #39424e;
  --placeholder-bg: #fff4d6;
  --placeholder-ink: #7a4b00;

  --font-en: "Inter", "Helvetica Neue", Arial, sans-serif;
  --font-ja: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;

  --maxw: 1120px;
  --radius: 6px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-en);
  font-size: 1rem;
  line-height: 1.6;
}

html[lang="ja"] body {
  font-family: var(--font-ja);
  line-height: 1.9;
  letter-spacing: 0.02em;
  font-feature-settings: "palt" 0;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--navy); text-underline-offset: 3px; }
a:hover { color: var(--teal-ink); }

:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

h1, h2, h3 { line-height: 1.35; margin: 0 0 0.6em; color: var(--navy); }
html[lang="ja"] h1, html[lang="ja"] h2, html[lang="ja"] h3 { line-height: 1.5; letter-spacing: 0.03em; }
h1 { font-size: clamp(1.75rem, 4vw, 2.6rem); font-weight: 700; }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--navy); color: var(--white); padding: 8px 14px; z-index: 100;
}
.skip-link:focus { left: 8px; top: 8px; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .container { padding: 0 32px; } }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--grey-100);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { flex: none; display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); font-weight: 700; letter-spacing: 0.02em; }
.brand img { width: 44px; height: auto; }
.brand span { font-size: 1.05rem; white-space: nowrap; }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  background: none; border: 1px solid var(--grey-100); border-radius: var(--radius);
  width: 44px; height: 44px; cursor: pointer; color: var(--navy);
}
.nav-toggle svg { width: 22px; height: 22px; }

.site-nav { display: none; }
.site-nav.open {
  display: block; position: absolute; left: 0; right: 0; top: 100%;
  background: var(--white); border-bottom: 1px solid var(--grey-100); padding: 8px 16px 20px;
}
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav li a { display: block; padding: 10px 0; text-decoration: none; color: var(--black); font-size: 0.95rem; white-space: nowrap; }
.site-nav li a[aria-current="page"] { color: var(--navy); font-weight: 700; }
.nav-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; align-items: center; }

.lang-switch { white-space: nowrap; flex: none; font-size: 0.85rem; display: inline-flex; gap: 2px; border: 1px solid var(--grey-100); border-radius: 999px; padding: 2px; }
.lang-switch a, .lang-switch span { padding: 4px 10px; border-radius: 999px; text-decoration: none; }
.lang-switch span[aria-current] { background: var(--navy); color: var(--white); }
.lang-switch a { color: var(--grey-700); }

@media (min-width: 1200px) {
  .nav-toggle { display: none; }
  .site-nav, .site-nav.open { display: flex; position: static; padding: 0; border: 0; align-items: center; gap: 18px; }
  .site-nav ul { display: flex; gap: 18px; }
  .site-nav li a { padding: 6px 0; }
  .nav-actions { margin-top: 0; flex-wrap: nowrap; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 10px 22px; border-radius: var(--radius);
  font: inherit; font-weight: 700; font-size: 0.95rem; text-decoration: none; cursor: pointer;
  border: 2px solid transparent; transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.btn-primary { background: var(--navy); color: var(--white); }
.btn-primary:hover { background: var(--navy-deep); color: var(--teal); }
.btn-accent { background: var(--teal); color: var(--navy-deep); }
.btn-accent:hover { background: var(--white); color: var(--navy-deep); }
.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.btn-outline-light { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.7); }
.btn-outline-light:hover { background: var(--white); color: var(--navy); }
.btn-sm { min-height: 38px; padding: 6px 16px; font-size: 0.85rem; white-space: nowrap; }
.btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
@media (min-width: 720px) { .section { padding: 88px 0; } }
.section-alt { background: var(--grey-50); }
.section-navy { background: var(--navy); color: var(--white); }
.section-navy h2, .section-navy h3 { color: var(--white); }
.section-navy a:not(.btn) { color: var(--teal); }

.eyebrow {
  display: inline-block; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--teal-ink); margin-bottom: 12px;
}
.section-navy .eyebrow, .hero .eyebrow { color: var(--teal); }
.eyebrow::before { content: ""; display: inline-block; width: 22px; height: 2px; background: var(--teal); vertical-align: middle; margin-right: 10px; }

.lead { font-size: 1.1rem; color: var(--grey-700); max-width: 46em; }
.section-navy .lead, .hero .lead { color: rgba(255,255,255,0.88); }
.muted { color: var(--grey-500); font-size: 0.9rem; }
.section-head { max-width: 760px; margin-bottom: 40px; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, var(--navy-deep) 0%, var(--navy) 60%, #0f3360 100%);
  color: var(--white); padding: 72px 0 80px; position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; right: -120px; top: -120px; width: 420px; height: 420px;
  border: 2px solid rgba(1, 213, 221, 0.35); border-radius: 50%; pointer-events: none;
}
.hero::before {
  content: ""; position: absolute; right: -10px; top: 0; width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(1,213,221,0.22) 0%, rgba(1,213,221,0) 70%); pointer-events: none;
}
.hero h1 { color: var(--white); max-width: 22em; }
.hero .container { position: relative; z-index: 1; }
.hero .btn-row { margin-top: 28px; }
.hero-sub { margin-top: 18px; font-size: 0.9rem; color: rgba(255,255,255,0.75); }
.page-hero { padding: 56px 0 56px; }
.page-hero h1 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); }

/* ---------- Grids & cards ---------- */
.grid { display: grid; gap: 20px; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .grid-4 { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 720px) and (max-width: 999px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }

.card {
  background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius);
  padding: 24px; border-top: 3px solid var(--teal);
}
.card h3 { margin-bottom: 0.4em; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.section-navy .card { background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.15); border-top-color: var(--teal); }
.section-navy .card p { color: rgba(255,255,255,0.88); }

.module-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.module-list li {
  display: grid; grid-template-columns: 48px 1fr; gap: 16px; align-items: start;
  background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius); padding: 20px;
}
.module-num {
  width: 48px; height: 48px; border-radius: 50%; background: var(--navy); color: var(--teal);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.1rem;
}
.module-list h3 { margin-bottom: 0.25em; }
.module-list p { margin: 0; color: var(--grey-700); }
.module-en { display: block; font-size: 0.82rem; color: var(--grey-500); font-weight: 400; letter-spacing: 0; }

.check-list { list-style: none; padding: 0; margin: 0 0 1em; }
.check-list li { position: relative; padding-left: 28px; margin-bottom: 0.5em; }
.check-list li::before {
  content: ""; position: absolute; left: 2px; top: 0.55em; width: 12px; height: 7px;
  border-left: 2px solid var(--teal-ink); border-bottom: 2px solid var(--teal-ink); transform: rotate(-45deg);
}
.section-navy .check-list li::before { border-color: var(--teal); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.info { width: 100%; border-collapse: collapse; background: var(--white); font-size: 0.95rem; }
table.info th, table.info td { text-align: left; vertical-align: top; padding: 14px 16px; border-bottom: 1px solid var(--grey-100); }
table.info th { width: 30%; min-width: 140px; background: var(--grey-50); color: var(--navy); font-weight: 700; }
@media (max-width: 600px) {
  table.info.stack th, table.info.stack td { display: block; width: 100%; }
  table.info.stack th { border-bottom: 0; padding-bottom: 6px; }
}

/* ---------- Steps (導入の流れ) ---------- */
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; display: grid; gap: 14px; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: step; background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius); padding: 20px; position: relative; }
.steps li::before { content: "STEP " counter(step); display: block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; color: var(--teal-ink); margin-bottom: 6px; }
.steps h3 { font-size: 1rem; }
.steps p { margin: 0; font-size: 0.92rem; color: var(--grey-700); }

/* ---------- Pricing ---------- */
.price-box { background: var(--white); border: 2px solid var(--navy); border-radius: var(--radius); padding: 28px; }
.price { font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 700; color: var(--navy); line-height: 1.2; margin: 6px 0 4px; }
.price small { font-size: 0.9rem; font-weight: 400; color: var(--grey-500); }
.tag { display: inline-block; font-size: 0.75rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--navy); color: var(--teal); letter-spacing: 0.05em; }

/* ---------- FAQ ---------- */
.faq details { border-bottom: 1px solid var(--grey-100); padding: 4px 0; }
.faq summary { cursor: pointer; list-style: none; padding: 16px 32px 16px 0; font-weight: 700; color: var(--navy); position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 12px; font-size: 1.4rem; color: var(--teal-ink); }
.faq details[open] summary::after { content: "−"; }
.faq details > div { padding: 0 0 16px; color: var(--grey-700); }

/* ---------- Placeholders (visible, deliberate) ---------- */
.ph {
  background: var(--placeholder-bg); color: var(--placeholder-ink); border: 1px dashed #d79b2b;
  padding: 1px 6px; border-radius: 3px; font-size: 0.9em; font-weight: 700;
}
.ph-block { display: block; padding: 14px 16px; margin: 0 0 1em; font-weight: 400; line-height: 1.7; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--navy); color: var(--white); padding: 56px 0; }
.cta-band h2 { color: var(--white); }
.cta-band p { color: rgba(255,255,255,0.88); max-width: 44em; }
.cta-options { display: grid; gap: 16px; margin-top: 28px; }
@media (min-width: 720px) { .cta-options { grid-template-columns: repeat(3, 1fr); } }
.cta-option { border: 1px solid rgba(255,255,255,0.2); border-radius: var(--radius); padding: 22px; display: flex; flex-direction: column; gap: 10px; }
.cta-option h3 { color: var(--white); margin: 0; font-size: 1.05rem; }
.cta-option p { margin: 0; font-size: 0.92rem; flex: 1; }
.cta-option.is-main { border: 2px solid var(--teal); }

/* ---------- Forms ---------- */
.form-card { background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius); padding: 24px; }
@media (min-width: 720px) { .form-card { padding: 36px; } }
.field { margin-bottom: 20px; }
.field label, .field legend { display: block; font-weight: 700; margin-bottom: 6px; color: var(--navy); font-size: 0.95rem; }
.req { display: inline-block; margin-left: 8px; font-size: 0.72rem; background: var(--navy); color: var(--white); padding: 1px 7px; border-radius: 3px; vertical-align: 2px; font-weight: 700; }
.opt { display: inline-block; margin-left: 8px; font-size: 0.72rem; background: var(--grey-100); color: var(--grey-700); padding: 1px 7px; border-radius: 3px; vertical-align: 2px; }
.field input[type="text"], .field input[type="email"], .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; padding: 12px 14px; border: 1px solid #b9c3cf; border-radius: var(--radius);
  background: var(--white); color: var(--black);
}
.field textarea { min-height: 160px; resize: vertical; line-height: 1.7; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--navy); outline: 3px solid rgba(1,213,221,0.45); outline-offset: 0; }
.field .hint { font-size: 0.85rem; color: var(--grey-500); margin-top: 4px; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: #b3261e; }
.error-msg { color: #b3261e; font-size: 0.85rem; margin-top: 6px; display: none; }
.field.has-error .error-msg { display: block; }
.checkbox { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; color: var(--black) !important; }
.checkbox input { margin-top: 0.4em; width: 18px; height: 18px; flex: none; }

.form-notice { display: none; border-radius: var(--radius); padding: 16px 18px; margin-top: 20px; line-height: 1.7; }
.form-notice.show { display: block; }
.form-notice.notice-warn { background: var(--placeholder-bg); border: 1px solid #d79b2b; color: #4d3000; }
.form-notice.notice-error { background: #fdecea; border: 1px solid #b3261e; color: #6b1510; }
.form-notice.notice-info { background: var(--grey-100); border: 1px solid var(--grey-100); color: var(--grey-700); }
.form-notice.notice-ok { background: #e6f7f8; border: 1px solid var(--teal-ink); color: var(--navy); }
.form-notice .btn { margin-top: 12px; }

.preview-banner {
  background: var(--placeholder-bg); color: #4d3000; border-bottom: 1px solid #d79b2b;
  font-size: 0.82rem; text-align: center; padding: 6px 16px;
}

/* ---------- Events embed ---------- */
.embed-frame { width: 100%; height: 640px; border: 1px solid #bfcbda88; border-radius: var(--radius); background: var(--white); }

/* ---------- Footer ---------- */
.site-footer { background: var(--grey-50); border-top: 3px solid var(--teal); padding: 48px 0 28px; font-size: 0.9rem; color: var(--grey-700); }
.footer-grid { display: grid; gap: 28px; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.site-footer h2 { font-size: 0.95rem; margin-bottom: 10px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 6px; }
.site-footer a { color: var(--grey-700); }
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.footer-brand img { width: 40px; }
.footer-bottom { margin-top: 32px; padding-top: 18px; border-top: 1px solid var(--grey-100); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; color: var(--grey-500); font-size: 0.82rem; }

/* ---------- Misc ---------- */
.two-col { display: grid; gap: 32px; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1fr 1fr; align-items: start; } .two-col.wide-left { grid-template-columns: 1.4fr 1fr; } }
.note { border-left: 3px solid var(--teal); background: var(--grey-50); padding: 14px 18px; font-size: 0.92rem; color: var(--grey-700); margin: 0 0 1em; }
.prose { max-width: 46em; }
.prose h2 { margin-top: 1.6em; font-size: 1.3rem; }
.prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.4em; }
.stack-sm > * + * { margin-top: 10px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Print (one-page overview) ---------- */
@media print {
  .site-header, .site-footer, .preview-banner, .no-print { display: none !important; }
  body { font-size: 10pt; }
}
