/* ==========================================================================
   ALILAND — shared styles
   Palette (confirmed): Navy #000080, Cyan #00FFFF, White
   Cyan is used as an accent (buttons, links, icons, highlights) rather than
   for body text, to keep contrast/readability on white backgrounds.
   ========================================================================== */

:root {
  --navy: #000080;
  --navy-dark: #00005c;
  --cyan: #00ffff;
  --cyan-deep: #0089a0; /* readable cyan for text-on-white */
  --white: #ffffff;
  --off-white: #f5f7fa;
  --ink: #16213e;
  --grey: #5b6472;
  --grey-light: #dfe3ea;
  --amber: #b45309;
  --radius: 10px;
  --max-width: 1180px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.55;
}

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

a { color: var(--cyan-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header / Nav ---------- */
.site-header {
  background: var(--navy);
  position: sticky;
  top: 0;
  z-index: 50;
}

.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.brand img { height: 40px; width: auto; display: block; }

.nav-links {
  display: none;
  gap: 22px;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--white);
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-links a:hover { color: var(--cyan); text-decoration: none; }

.nav-links a.forum-link {
  border: 1px solid var(--cyan);
  border-radius: 999px;
  padding: 6px 16px;
  color: var(--cyan);
}
.nav-links a.forum-link:hover { background: var(--cyan); color: var(--navy); }

.nav-lang {
  color: var(--white);
  font-size: 0.8rem;
  opacity: 0.8;
}

.nav-toggle {
  display: inline-block;
  background: none;
  border: 1px solid var(--cyan);
  color: var(--cyan);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 0.85rem;
  cursor: pointer;
}

@media (min-width: 900px) {
  .nav-links { display: flex; }
  .nav-toggle { display: none; }
}

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: var(--navy-dark);
  padding: 10px 20px 16px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  color: var(--white);
  padding: 10px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  font-size: 0.95rem;
}
.mobile-menu a.forum-link { color: var(--cyan); font-weight: 600; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-dark) 100%);
  color: var(--white);
  padding: 56px 0 64px;
}
.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}
.hero h1 {
  font-size: 2rem;
  line-height: 1.2;
  margin: 0 0 14px;
  max-width: 680px;
}
.hero p.sub {
  font-size: 1.05rem;
  color: #cfe9ee;
  max-width: 560px;
  margin: 0 0 26px;
}
@media (min-width: 700px) {
  .hero h1 { font-size: 2.6rem; }
}

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 30px; }

.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: 2px solid transparent;
}
.btn-primary { background: var(--cyan); color: var(--navy); }
.btn-primary:hover { background: #7dfcfc; text-decoration: none; }
.btn-outline { background: transparent; color: var(--white); border-color: var(--cyan); }
.btn-outline:hover { background: rgba(0,255,255,0.1); text-decoration: none; }

.search-bar {
  display: flex;
  background: var(--white);
  border-radius: 999px;
  overflow: hidden;
  max-width: 560px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}
.search-bar input {
  flex: 1;
  border: none;
  padding: 14px 18px;
  font-size: 0.95rem;
  outline: none;
  font-family: var(--font);
}
.search-bar button {
  background: var(--navy);
  color: var(--white);
  border: none;
  padding: 0 22px;
  font-weight: 600;
  cursor: pointer;
}
.search-bar button:hover { background: var(--navy-dark); }

/* ---------- Sections ---------- */
section.block { padding: 48px 0; }
section.block.alt { background: var(--off-white); }

.section-head { margin-bottom: 26px; }
.section-head h2 { font-size: 1.5rem; margin: 0 0 8px; color: var(--navy); }
.section-head p { color: var(--grey); margin: 0; max-width: 620px; }

/* Pillar tiles */
.pillar-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
@media (min-width: 700px) {
  .pillar-grid { grid-template-columns: repeat(3, 1fr); }
}
.pillar-tile {
  display: block;
  background: var(--white);
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: 20px 18px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.pillar-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(0,0,128,0.12);
  text-decoration: none;
}
.pillar-tile .tile-icon {
  width: 34px; height: 34px; border-radius: 8px;
  background: var(--navy); color: var(--cyan);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; margin-bottom: 12px; font-size: 0.95rem;
}
.pillar-tile h3 { margin: 0 0 6px; font-size: 1.02rem; color: var(--ink); }
.pillar-tile p { margin: 0; font-size: 0.85rem; color: var(--grey); }

/* Cards (guides feed) */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
@media (min-width: 700px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}
.card {
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
}
.card .card-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--cyan-deep);
  text-transform: uppercase;
  margin: 16px 18px 6px;
}
.card h3 { margin: 0 18px 10px; font-size: 1.05rem; }
.card p { margin: 0 18px 18px; color: var(--grey); font-size: 0.9rem; }

/* Featured guide */
.featured {
  display: grid;
  gap: 20px;
  background: var(--navy);
  color: var(--white);
  border-radius: 14px;
  padding: 28px;
}
@media (min-width: 800px) {
  .featured { grid-template-columns: 1.2fr 1fr; align-items: center; }
}
.featured .tag {
  color: var(--cyan);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.featured h2 { margin: 8px 0 12px; font-size: 1.6rem; }
.featured p { color: #cfe9ee; margin: 0 0 18px; }

/* Forum highlight */
.forum-box {
  border: 1.5px solid var(--navy);
  border-radius: var(--radius);
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
@media (min-width: 700px) {
  .forum-box { flex-direction: row; align-items: center; justify-content: space-between; }
}
.forum-box .snippet {
  background: var(--off-white);
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 0.9rem;
  color: var(--grey);
  max-width: 480px;
}

/* Tools */
.tools-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
@media (min-width: 700px) {
  .tools-grid { grid-template-columns: repeat(2, 1fr); }
}
.tool-card {
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: 24px;
  position: relative;
}
.badge-soon {
  position: absolute;
  top: 18px; right: 18px;
  background: var(--amber);
  color: var(--white);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.tool-card h3 { margin: 0 0 8px; color: var(--navy); }
.tool-card p { color: var(--grey); margin: 0 0 14px; font-size: 0.92rem; }

/* Quick Answer box */
.quick-answer {
  background: var(--off-white);
  border-left: 5px solid var(--cyan-deep);
  border-radius: 8px;
  padding: 18px 20px;
  margin: 20px 0 28px;
}
.quick-answer .qa-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--cyan-deep);
  margin-bottom: 6px;
}
.quick-answer p { margin: 0; }

/* Footer */
.site-footer {
  background: var(--navy-dark);
  color: #c9d3e0;
  padding: 44px 0 26px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-bottom: 30px;
}
@media (min-width: 700px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}
.footer-grid h4 {
  color: var(--white);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 14px;
}
.footer-grid a { color: #c9d3e0; display: block; margin-bottom: 8px; font-size: 0.9rem; }
.footer-grid a:hover { color: var(--cyan); }
.footer-grid a.external::after { content: " ↗"; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 18px;
  font-size: 0.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
}

/* Generic page header (About / Contact / Tools / Knowledge) */
.page-hero {
  background: var(--navy);
  color: var(--white);
  padding: 40px 0;
}
.page-hero h1 { margin: 0 0 8px; font-size: 1.9rem; }
.page-hero p { margin: 0; color: #cfe9ee; max-width: 620px; }

.breadcrumb { font-size: 0.85rem; color: var(--grey); margin-bottom: 16px; }
.breadcrumb a { color: var(--cyan-deep); }

.values-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 700px) {
  .values-grid { grid-template-columns: repeat(3, 1fr); }
}
.value-card {
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: 20px;
}
.value-card h3 { margin: 0 0 8px; color: var(--navy); font-size: 1rem; }
.value-card p { margin: 0; color: var(--grey); font-size: 0.9rem; }

.form-field { margin-bottom: 16px; }
.form-field label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--grey-light);
  border-radius: 8px;
  font-family: var(--font);
  font-size: 0.92rem;
}
.form-field textarea { min-height: 120px; resize: vertical; }

.directory-filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.directory-filters select {
  padding: 9px 12px;
  border: 1px solid var(--grey-light);
  border-radius: 8px;
  font-family: var(--font);
}

.directory-list { display: grid; gap: 12px; }
.directory-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--grey-light);
  border-radius: var(--radius);
  padding: 16px 18px;
  flex-wrap: wrap;
  gap: 8px;
}
.directory-item .verified {
  color: var(--cyan-deep);
  font-size: 0.75rem;
  font-weight: 700;
}

.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.tab {
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--grey-light);
  background: var(--white);
  font-size: 0.85rem;
  cursor: pointer;
}
.tab.active { background: var(--navy); color: var(--white); border-color: var(--navy); }

.toc {
  background: var(--off-white);
  border-radius: 8px;
  padding: 16px 20px;
  margin: 24px 0;
}
.toc h4 { margin: 0 0 10px; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--grey); }
.toc ol { margin: 0; padding-left: 20px; }
.toc a { color: var(--ink); }

.guide-body h2 { color: var(--navy); font-size: 1.25rem; margin-top: 32px; }
.guide-meta { color: var(--grey); font-size: 0.85rem; margin-bottom: 6px; }

.related-box {
  background: var(--off-white);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 36px;
}
.related-box h4 { margin: 0 0 12px; color: var(--navy); }

/* Form status messages (Contact page) */
.form-status { border-radius: 8px; padding: 12px 16px; font-size: 0.88rem; }
.form-status.success { background: #e7fbe9; border: 1px solid #8fd39c; color: #14622a; margin-bottom: 20px; }
.form-status.error { background: #fdecec; border: 1px solid #e79b9b; color: #7a1c1c; margin-bottom: 20px; }
#contact-status:empty { display: none; }

/* Social icons (Contact page) */
.social-heading { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--navy); margin: 0 0 12px; }
.social-icons { display: flex; gap: 12px; }
.social-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  transition: background 0.15s ease;
}
.social-icon:hover { background: var(--navy-dark); text-decoration: none; }
.social-icon svg { width: 19px; height: 19px; }
