/* ==========================================================================
   Monehatak Unipessoal LDA — Clean, bright theme
   Palette inspired by the Timor-Leste national flag (red / black / yellow /
   white) but tuned for a light, high-contrast, easy-to-read layout.
   ========================================================================== */

:root {
  /* brand accents */
  --tl-red: #D62828;
  --tl-red-dark: #A61E1E;
  --tl-red-soft: #FCEAEA;
  --tl-yellow: #B8790C;        /* amber — used for accent text/labels (readable on white) */
  --tl-yellow-bright: #FFC72C; /* flag yellow — used for gradients/highlights on dark surfaces */
  --tl-yellow-soft: #FFF6E0;
  --tl-black: #1A1D23;         /* near-black, flag stripe + strong ink */

  /* text */
  --tl-white: #1C1F26;         /* primary text (dark ink, kept name for template compatibility) */
  --tl-muted: #626878;         /* secondary text */

  /* surfaces */
  --bg: #FFFFFF;
  --bg-soft: #F6F7FA;
  --panel: #FFFFFF;
  --border: #E6E8EF;

  --radius: 16px;
  --shadow-sm: 0 2px 10px rgba(20, 22, 30, 0.06);
  --shadow-md: 0 16px 40px rgba(20, 22, 30, 0.12);

  --font-head: 'Poppins', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', Tahoma, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--tl-white);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* very subtle dot grid + soft brand glow at the top of the page */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image:
    linear-gradient(rgba(20, 22, 30, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 22, 30, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse at 50% 0%, black 0%, transparent 55%);
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -3;
  background: radial-gradient(ellipse 900px 480px at 50% -10%, rgba(214, 40, 40, 0.06), transparent 60%);
}

h1, h2, h3, h4, .brand, .btn, .stat-number {
  font-family: var(--font-head);
  letter-spacing: 0.01em;
}

a { color: inherit; text-decoration: none; }

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

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--tl-white);
}

.brand img {
  height: 42px;
  width: 42px;
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.brand .brand-sub {
  display: block;
  font-family: var(--font-body);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  color: var(--tl-red);
  font-weight: 700;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-weight: 600;
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.nav-links a {
  color: var(--tl-muted);
  position: relative;
  padding-bottom: 4px;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--tl-red);
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 2px;
  background: linear-gradient(90deg, var(--tl-red), var(--tl-yellow-bright));
  border-radius: 2px;
}

.nav-cta {
  padding: 10px 20px;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--tl-red), var(--tl-red-dark));
  color: #fff !important;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 20px rgba(214, 40, 40, 0.25);
  transition: transform 0.2s, box-shadow 0.2s;
}
.nav-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(214, 40, 40, 0.32); }

.nav-toggle { display: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, color 0.2s, border-color 0.2s;
}

.btn-primary {
  background: linear-gradient(120deg, var(--tl-red), var(--tl-red-dark));
  color: #fff;
  box-shadow: 0 8px 22px rgba(214, 40, 40, 0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(214, 40, 40, 0.32); }

.btn-outline {
  background: var(--bg);
  color: var(--tl-white);
  border-color: var(--border);
}
.btn-outline:hover { border-color: var(--tl-red); color: var(--tl-red); }

.btn-red {
  background: linear-gradient(120deg, var(--tl-yellow-bright), #E8A200);
  color: #241a02;
  box-shadow: 0 8px 22px rgba(255, 199, 44, 0.3);
}
.btn-red:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(255, 199, 44, 0.38); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 120px 0 90px;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -200px; right: -150px;
  width: 560px; height: 560px;
  background: radial-gradient(circle, rgba(214, 40, 40, 0.10) 0%, transparent 70%);
  filter: blur(10px);
  z-index: -1;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -220px; left: -160px;
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(255, 199, 44, 0.16) 0%, transparent 70%);
  z-index: -1;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--tl-red);
  background: var(--tl-red-soft);
  border: 1px solid rgba(214, 40, 40, 0.18);
  padding: 7px 16px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--tl-red); }

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.15;
  margin: 0 0 22px;
  max-width: 780px;
  color: var(--tl-white);
}

.hero h1 .accent {
  background: linear-gradient(120deg, var(--tl-red), #E8A200);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p.lead {
  max-width: 640px;
  color: var(--tl-muted);
  font-size: 1.15rem;
  margin-bottom: 34px;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 56px; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 18px;
  max-width: 760px;
}

.stat-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  background: var(--bg);
  box-shadow: var(--shadow-sm);
}
.stat-number { font-size: 1.7rem; color: var(--tl-red); }
.stat-label { font-size: 0.78rem; color: var(--tl-muted); text-transform: uppercase; letter-spacing: 0.05em; }

/* ---------- Sections ---------- */
section { padding: 90px 0; position: relative; }

.section-head { max-width: 640px; margin: 0 auto 52px; text-align: center; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin: 10px 0 14px; color: var(--tl-white); }
.section-head p { color: var(--tl-muted); }
.section-head .eyebrow { display: inline-flex; }

.section-alt { background: var(--bg-soft); }

/* ---------- Cards / grid ---------- */
.grid {
  display: grid;
  gap: 26px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.card:hover {
  transform: translateY(-6px);
  border-color: var(--tl-red);
  box-shadow: var(--shadow-md);
}
.card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--tl-red), var(--tl-yellow-bright));
  opacity: 0; transition: opacity 0.25s;
}
.card:hover::before { opacity: 1; }

.icon-badge {
  width: 54px; height: 54px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: var(--tl-red-soft);
  color: var(--tl-red);
  margin-bottom: 18px;
  font-size: 1.5rem;
  border: 1px solid rgba(214, 40, 40, 0.15);
}

.card h3 { margin: 0 0 10px; font-size: 1.15rem; color: var(--tl-white); }
.card p { color: var(--tl-muted); margin: 0; font-size: 0.96rem; }

.tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--tl-red);
  background: var(--bg);
  margin-bottom: 14px;
}

/* project card image */
.project-card { display: flex; flex-direction: column; }
.project-media {
  height: 180px;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 18px;
  background: linear-gradient(135deg, #F1F2F5, #E6E8EF);
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--border);
}
.project-media img { height: 100%; width: 100%; object-fit: cover; }
.project-media .placeholder-icon { font-size: 2.4rem; color: var(--tl-muted); opacity: 0.6; }

.meta-row { display: flex; gap: 14px; flex-wrap: wrap; font-size: 0.82rem; color: var(--tl-muted); margin: 10px 0 14px; }
.meta-row span { display: flex; align-items: center; gap: 6px; }

/* ---------- Timeline / About ---------- */
.two-col {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: start;
}

.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  background: var(--bg-soft);
}

.flag-strip { display: flex; height: 6px; border-radius: 999px; overflow: hidden; margin: 26px 0; border: 1px solid var(--border); }
.flag-strip span { flex: 1; }
.flag-strip .c1 { background: var(--tl-red); }
.flag-strip .c2 { background: var(--tl-black); }
.flag-strip .c3 { background: var(--tl-yellow-bright); }
.flag-strip .c4 { background: #EDEEF2; }

.stat-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 26px; }

/* ---------- Forms ---------- */
.form-panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  background: var(--bg);
  box-shadow: var(--shadow-sm);
  max-width: 680px;
  margin: 0 auto;
}

.field { margin-bottom: 20px; }
.field label { display: block; font-size: 0.82rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--tl-red); margin-bottom: 8px; }

input, select, textarea {
  width: 100%;
  padding: 13px 16px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--tl-white);
  font-family: var(--font-body);
  font-size: 1rem;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--tl-red);
  box-shadow: 0 0 0 3px rgba(214, 40, 40, 0.12);
}

.errorlist { color: var(--tl-red); list-style: none; padding: 0; margin: 6px 0 0; font-size: 0.85rem; }

.alert {
  padding: 14px 18px;
  border-radius: 10px;
  border: 1px solid var(--tl-yellow-bright);
  background: var(--tl-yellow-soft);
  color: var(--tl-yellow);
  margin-bottom: 22px;
  font-weight: 600;
}

/* ---------- QR / verification ---------- */
.qr-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  text-align: center;
  padding: 34px;
  border: 1px dashed var(--tl-yellow-bright);
  border-radius: var(--radius);
  background: var(--bg-soft);
}
.qr-box img { width: 220px; height: 220px; border-radius: 12px; background: #fff; padding: 10px; border: 1px solid var(--border); }
.ref-code {
  font-family: 'Courier New', monospace;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  padding: 10px 18px;
  border-radius: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--tl-yellow);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}
.status-pending { background: #FFF6E0; color: #8A6100; border: 1px solid #E8B923; }
.status-approved { background: #E7F8F0; color: #1E8E5A; border: 1px solid #2FBE7F; }
.status-rejected { background: #FCEAEA; color: #C62828; border: 1px solid var(--tl-red); }
.status-completed { background: #EEF1FF; color: #4C5FD5; border: 1px solid #7C8FFF; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 60px 0 30px;
  margin-top: 60px;
  background: var(--tl-black);
  color: #A9AEBC;
}
.site-footer .brand { color: #fff; }
.site-footer .brand .brand-sub { color: var(--tl-yellow-bright); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-grid h4 { color: var(--tl-yellow-bright); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.07em; margin-bottom: 16px; }
.footer-grid p, .footer-grid a { color: #A9AEBC; font-size: 0.92rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-grid a:hover { color: var(--tl-yellow-bright); }
.footer-bottom {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.8rem;
  color: #7C8195;
}

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 10px; justify-content: center; margin-top: 40px; }
.pagination a, .pagination span {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--tl-muted);
}
.pagination a:hover { color: var(--tl-red); border-color: var(--tl-red); }
.pagination .current { color: #fff; background: var(--tl-red); border-color: var(--tl-red); font-weight: 700; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.muted { color: var(--tl-muted); }
.small { font-size: 0.85rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero { padding: 90px 0 60px; }
}