/* Japan Travel Health */

/* Base */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
    background: #f5f5f5;
    margin: 0;
    padding: 0;
    color: #111;
}

header nav {
    padding: 16px 24px;
    background: #fff;
    border-bottom: 2px solid #e0e0e0;
    font-size: 16px;
}

header nav a {
    text-decoration: none;
    color: #c0392b;
    font-weight: bold;
}

main {
    max-width: 600px;
    margin: 0 auto;
    padding: 24px 16px 48px;
}

/* Card-only view (shareable link / generated card) */
body.card-view .hero,
body.card-view .reassurance,
body.card-view .guide,
body.card-view .presets,
body.card-view .tool-label,
body.card-view .builder-intro,
html.card-view-early .hero,
html.card-view-early .reassurance,
html.card-view-early .guide,
html.card-view-early .presets,
html.card-view-early .tool-label,
html.card-view-early .builder-intro {
    display: none;
}

body.card-view .tool-section,
html.card-view-early .tool-section {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    min-height: 0;
}

html.card-view-early #builder {
    display: none;
}

#card-output:empty {
    display: none;
}

html.card-view-early #card-output {
    display: block;
    min-height: 100vh;
}

body.card-view .landing,
html.card-view-early .landing {
    max-width: 700px;
    padding-left: 0;
    padding-right: 0;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Landing page */
.landing {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 16px 64px;
}

.hero {
    padding: 19px 0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 19px;
}

.hero h1 {
    font-size: 29px;
    line-height: 1.25;
    margin: 0 0 13px;
    color: #111;
}

.hero-sub {
    font-size: 18px;
    color: #444;
    margin: 0 0 24px;
}

.cta-btn {
    display: inline-block;
    background: #c0392b;
    color: #fff;
    padding: 14px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 16px;
}

.cta-btn.secondary {
    background: #1a4a7a;
}

.reassurance {
    margin-bottom: 32px;
}

.reassurance ul {
    padding-left: 19px;
    margin: 0 0 19px;
    color: #333;
    line-height: 2;
}

.tool-section {
    background: #eef4fb;
    border: 2px solid #b0cce8;
    border-radius: 12px;
    padding: 24px 19px;
    margin-bottom: 40px;
    min-height: 280px;
}

.tool-label {
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #1a4a7a;
    margin-bottom: 16px;
}

.tool-section .builder-intro h2 {
    margin: 0 0 5px;
    font-size: 21px;
}

.tool-section .builder-intro p {
    margin: 0 0 19px;
    color: #555;
    font-size: 15px;
}

.guide {
    color: #222;
    line-height: 1.7;
    margin-bottom: 32px;
}

.guide h2 {
    font-size: 21px;
    margin: 32px 0 10px;
    color: #111;
}

.guide p, .guide ul, .guide ol {
    margin: 0 0 16px;
}

.guide ul, .guide ol {
    padding-left: 22px;
}

.guide li {
    margin-bottom: 6px;
}

.inline-cta {
    background: #f9f9f9;
    border-left: 3px solid #c0392b;
    padding: 16px 19px;
    margin: 32px 0;
    border-radius: 0 8px 8px 0;
}

.inline-cta p {
    margin: 0 0 11px;
    font-weight: 600;
}

/* Builder */
.builder-intro {
    text-align: center;
    margin-bottom: 32px;
}

.builder-intro h1 {
    font-size: 26px;
    margin-bottom: 6px;
}

.builder-intro p {
    color: #666;
    font-size: 16px;
    margin: 0;
}

.step-back {
    background: none;
    border: none;
    color: #888;
    font-size: 14px;
    cursor: pointer;
    padding: 0 0 16px 0;
    display: block;
}

.step-question {
    margin-bottom: 19px;
}

.step-q-en {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 3px;
}

.step-q-ja {
    display: none;
    font-size: 16px;
    color: #888;
}

body.learning-mode .step-q-ja {
    display: block;
}

.opt-ja {
    display: none;
}

body.learning-mode .opt-ja {
    display: block;
}

.step-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.step-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 19px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    text-align: left;
    font-size: 16px;
    transition: border-color 0.15s, background 0.15s;
}

.step-option:hover {
    border-color: #b0cce8;
}

.step-option.selected {
    border-color: #1a4a7a;
    background: #eef4fb;
}

.opt-en {
    font-weight: 600;
    color: #111;
}

.opt-ja {
    color: #888;
    font-size: 15px;
}

.step-none .opt-en {
    color: #888;
    font-weight: normal;
}

.step-continue {
    display: block;
    width: 100%;
    margin-top: 16px;
    padding: 16px;
    background: #c0392b;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
}

/* Share bar */
.share-bar {
    display: flex;
    gap: 13px;
    margin-bottom: 24px;
}

.share-btn {
    flex: 1;
    padding: 8px 6px;
    border-radius: 8px;
    border: none;
    font-size: 15px;
    cursor: pointer;
    font-weight: 600;
    background: #1a4a7a;
    color: #fff;
}

.share-btn.secondary {
    background: #e0e0e0;
    color: #333;
}

/* Presets */
.presets {
    margin-top: 48px;
    border-top: 1px solid #e0e0e0;
    padding-top: 24px;
}

.presets h2 {
    font-size: 16px;
    color: #888;
    font-weight: normal;
    margin-bottom: 13px;
}

.preset-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.preset-links a {
    color: #c0392b;
    text-decoration: none;
    font-size: 16px;
    padding: 6px 0;
}

.preset-links a:hover {
    text-decoration: underline;
}

footer {
    text-align: center;
    padding: 32px;
    color: #aaa;
    font-size: 14px;
}

/* Modal */
#intake-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

#intake-modal {
    background: #fff;
    border-radius: 8px;
    padding: 32px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

#intake-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 19px;
    cursor: pointer;
}
