/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Noto Serif JP', serif; color: #333; line-height: 1.5; }
h1,h2,h3,h4,h5,h6 { font-family: 'Noto Serif JP', serif; }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

.font-serif-country { font-family: Georgia, 'Times New Roman', serif; }

/* ===== Layout ===== */
.max-w-3xl { max-width: 48rem; margin-left: auto; margin-right: auto; }
.max-w-4xl { max-width: 56rem; margin-left: auto; margin-right: auto; }
.max-w-5xl { max-width: 64rem; margin-left: auto; margin-right: auto; }
.max-w-6xl { max-width: 72rem; margin-left: auto; margin-right: auto; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }

/* ===== Components ===== */

/* Header */
.site-header { background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.1); position: sticky; top: 0; z-index: 50; }
.site-header .header-inner { max-width: 72rem; margin: 0 auto; padding: .75rem 1rem; display: flex; align-items: center; justify-content: space-between; }
.site-header .logo { display: flex; align-items: center; gap: .5rem; text-decoration: none; }
.site-header .logo img { height: 2rem; width: auto; }
.site-header .logo span { font-size: 1.125rem; font-weight: 700; color: #1f2937; }
.site-header nav.desktop { display: none; gap: 2rem; }
.site-header nav.desktop a { color: #6b7280; font-size: .875rem; font-weight: 500; font-family: Georgia, 'Times New Roman', serif; }
.site-header nav.desktop a:hover { color: #1f2937; }
.mobile-toggle { display: block; color: #4b5563; font-size: 1.5rem; background: none; border: none; cursor: pointer; }
.mobile-nav { display: none; border-top: 1px solid #e5e7eb; padding: .75rem 1rem; background: #fff; }
.mobile-nav.open { display: block; }
.mobile-nav a { display: block; color: #4b5563; font-size: .875rem; padding: .25rem 0; }
.header-banner { background: #f9fafb; border-top: 1px solid #e5e7eb; }
.header-banner p { max-width: 72rem; margin: 0 auto; padding: .5rem 1rem; font-size: 11px; color: #9ca3af; text-align: center; }

/* Hero slider */
.hero-slider { position: relative; min-height: 420px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.hero-slide { position: absolute; inset: 0; transition: opacity 1s; opacity: 0; }
.hero-slide.active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.1); transition: transform .05s linear; }
.hero-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.45); }
.hero-content { position: relative; z-index: 10; max-width: 56rem; margin: 0 auto; padding: 5rem 1rem; text-align: center; color: #fff; }
.hero-content h1 { font-size: 1.875rem; font-weight: 700; margin-bottom: 1rem; line-height: 1.25; }
.hero-content p { color: #e5e7eb; font-size: 1rem; margin-top: 1rem; }

/* Country cards */
.country-cards { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
.country-card { display: block; border-radius: .5rem; overflow: hidden; box-shadow: 0 4px 6px rgba(0,0,0,.1); transition: box-shadow .3s; background: #fff; }
.country-card:hover { box-shadow: 0 10px 25px rgba(0,0,0,.15); }
.country-card .card-img { height: 10rem; overflow: hidden; }
.country-card .card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.country-card:hover .card-img img { transform: scale(1.05); }
.country-card .card-body { padding: 1rem; }
.country-card .card-body h3 { font-family: Georgia, 'Times New Roman', serif; font-size: 1.125rem; font-weight: 700; color: #1f2937; }

/* Section heading with accent */
.section-title { font-size: 1.5rem; font-weight: 700; color: #1f2937; margin-bottom: .5rem; }
.accent-line { width: 4rem; height: 2px; background: #c41e3a; margin-bottom: 2rem; }

/* Bullet list */
.bullet-list { list-style: none; }
.bullet-list li { display: flex; align-items: center; gap: .75rem; color: #374151; font-size: 15px; padding: 0; }
.bullet-dot { width: .5rem; height: .5rem; background: #1f2937; border-radius: 50%; flex-shrink: 0; }

/* Country section (alternating image+text) */
.country-section { display: grid; gap: 0; grid-template-columns: 1fr; }
.country-section .section-img { min-height: 16rem; }
.country-section .section-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.country-section .section-text { padding: 2rem; display: flex; flex-direction: column; justify-content: center; }
.section-text h2 { font-family: Georgia, 'Times New Roman', serif; font-size: 1.5rem; font-weight: 700; color: #1f2937; margin-bottom: 1rem; }
.section-text p { color: #374151; line-height: 1.625; font-size: 15px; margin-bottom: 0; }
.section-text .btn { display: inline-block; color: #fff; padding: .625rem 1.5rem; border-radius: .25rem; font-size: .875rem; margin-top: 1.5rem; transition: filter .2s; width: fit-content; }
.section-text .btn:hover { filter: brightness(1.15); }

/* Country page hero with image */
.country-hero { position: relative; min-height: 350px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.country-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.country-hero .overlay { position: absolute; inset: 0; background: rgba(0,0,0,.4); }
.country-hero .hero-text { position: relative; z-index: 10; text-align: center; color: #fff; }
.country-hero .hero-text h1 { font-family: Georgia, 'Times New Roman', serif; font-size: 2.25rem; font-weight: 700; letter-spacing: .05em; }
.country-hero .hero-text p { margin-top: .75rem; color: #e5e7eb; font-size: .875rem; }

/* Gradient hero (USA, Korea, UK pages) */
.gradient-hero { padding: 4rem 1rem; text-align: center; color: #fff; }
.gradient-hero h1 { font-family: Georgia, 'Times New Roman', serif; font-size: 1.875rem; font-weight: 700; margin-bottom: 1rem; }
.gradient-hero p { font-size: .875rem; }
.gradient-usa { background: linear-gradient(135deg, #b91c1c, #7f1d1d); }
.gradient-korea { background: linear-gradient(135deg, #15803d, #14532d); }
.gradient-uk { background: linear-gradient(135deg, #7e22ce, #581c87); }

/* Legal page hero */
.legal-hero { background: #1f2937; color: #fff; padding: 3rem 1rem; text-align: center; }
.legal-hero h1 { font-size: 1.875rem; font-weight: 700; margin-bottom: .5rem; }
.legal-hero p { color: #9ca3af; }

/* Article content */
.article-content { max-width: 56rem; margin: 0 auto; padding: 3rem 1rem; }
.article-content > p { color: #374151; line-height: 1.625; font-size: 15px; }
.article-content .space-y > * + * { margin-top: 2.5rem; }

/* Article section with border */
.article-section { margin-bottom: 2.5rem; }
.article-section h2 { font-size: 1.25rem; font-weight: 700; color: #1f2937; margin-bottom: 1rem; padding-bottom: .5rem; border-bottom: 1px solid #e5e7eb; }
.article-section .content { color: #374151; line-height: 1.625; font-size: 15px; }
.article-section .content p + p { margin-top: 1rem; }
.article-section .content ul { list-style: disc; padding-left: 1.5rem; margin-top: .75rem; }
.article-section .content ul li { margin-bottom: .5rem; }
.article-section .content ul li + li { margin-top: .5rem; }

/* Legal article section (no border) */
.legal-section { margin-bottom: 2rem; }
.legal-section h2 { font-size: 1.25rem; font-weight: 700; color: #1f2937; margin-bottom: 1rem; }
.legal-section .content { color: #374151; line-height: 1.625; }
.legal-section .content p + p { margin-top: .75rem; }

/* Visa type card */
.visa-type { padding-left: 1rem; border-left: 2px solid #d1d5db; margin-bottom: 1rem; }
.visa-type h4 { font-weight: 700; color: #1f2937; margin-bottom: .25rem; }
.visa-type p { font-size: .875rem; color: #374151; }

/* Notice box */
.notice-box { padding: 1.25rem; background: #fefce8; border: 1px solid #fde68a; border-radius: .5rem; font-size: .875rem; color: #374151; margin-top: 1.5rem; }
.notice-box .notice-title { font-weight: 700; margin-bottom: .5rem; }
.notice-box a { color: #2563eb; text-decoration: underline; }
.notice-box p + p { margin-top: .5rem; }

/* FAQ */
.faq-section { padding: 3rem 0; }
.faq-title { font-size: 1.5rem; font-weight: 700; color: #1f2937; margin-bottom: 2rem; text-align: center; }
.faq-item { border: 1px solid #e5e7eb; border-radius: .5rem; overflow: hidden; margin-bottom: .75rem; }
.faq-item button { width: 100%; padding: 1rem 1.25rem; text-align: left; display: flex; align-items: center; justify-content: space-between; gap: 1rem; background: none; border: none; cursor: pointer; font: inherit; }
.faq-item button:hover { background: #f9fafb; }
.faq-item .q-text { display: flex; align-items: center; gap: .75rem; }
.faq-item .q-num { font-size: .875rem; font-weight: 700; color: #9ca3af; width: 1.5rem; }
.faq-item .q-label { font-weight: 500; color: #1f2937; }
.faq-item .toggle { color: #9ca3af; font-size: 1.25rem; flex-shrink: 0; }
.faq-item .answer { padding: 0 1.25rem 1rem 3.5rem; color: #4b5563; font-size: .875rem; line-height: 1.625; display: none; }
.faq-item.open .answer { display: block; }

/* Footer */
.site-footer { background: #1a1a1a; color: #fff; }
.footer-inner { max-width: 64rem; margin: 0 auto; padding: 3.5rem 1rem; }
.footer-logo { display: flex; align-items: center; justify-content: center; gap: .5rem; margin-bottom: 1rem; }
.footer-logo img { height: 2.5rem; width: auto; }
.footer-logo h3 { font-weight: 700; font-size: 1.25rem; }
.footer-desc { color: #9ca3af; font-size: .875rem; line-height: 1.625; max-width: 48rem; margin: 0 auto 1rem; text-align: center; }
.footer-note { color: #6b7280; font-size: .75rem; line-height: 1.625; max-width: 48rem; margin: 0 auto 1rem; text-align: center; }
.footer-links { border-top: 1px solid #374151; padding-top: 2rem; margin-top: 2rem; display: flex; flex-direction: column; gap: 1rem; }
.footer-links a { color: #9ca3af; font-size: .875rem; }
.footer-links a:hover { color: #fff; }
.footer-links .link-group { display: flex; flex-wrap: wrap; gap: 1rem; }
.footer-copy { border-top: 1px solid #374151; margin-top: 2rem; padding-top: 1.5rem; text-align: center; color: #6b7280; font-size: .75rem; }

/* Country nav bottom */
.country-nav { background: #f9fafb; padding: 100px 1rem; }
.country-nav h2 { font-size: 1.5rem; font-weight: 700; color: #1f2937; margin-bottom: 2rem; text-align: center; }

/* Gray bg section */
.bg-section-gray { background: #f9fafb; padding: 3.5rem 1rem; }
.bg-section-white { padding: 3.5rem 1rem; }

/* Scroll margin for anchors */
[id] { scroll-margin-top: 5rem; }

/* Space between paragraphs */
.space-y-4 > * + * { margin-top: 1rem; }

/* ===== Responsive ===== */
@media (min-width: 640px) {
  .country-cards { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 768px) {
  .site-header nav.desktop { display: flex; }
  .mobile-toggle { display: none; }
  .hero-slider { min-height: 480px; }
  .hero-content h1 { font-size: 3rem; }
  .section-title { font-size: 1.875rem; }
  .country-section { grid-template-columns: repeat(2, 1fr); }
  .country-section.reverse .section-img { order: 2; }
  .country-section.reverse .section-text { order: 1; }
  .section-text { padding: 3rem; }
  .section-text h2 { font-size: 1.875rem; }
  .country-hero { min-height: 400px; }
  .country-hero .hero-text h1 { font-size: 3.75rem; }
  .gradient-hero h1 { font-size: 2.25rem; }
  .footer-links { flex-direction: row; justify-content: space-between; align-items: start; }
  .br-md { display: inline; }
}
@media (min-width: 1024px) {
  .country-cards { grid-template-columns: repeat(4, 1fr); }
}
.br-md { display: none; }
