/* assets/css/style.css */

/* ====== HEADER (responsive) ====== */
.site-header {
  position: sticky;           /* make sticky; change to 'static' if you prefer */
  top: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #004080;
  color: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

/* Brand / Logo */
.brand {
  display: flex;
  align-items: center;
  min-width: 0; /* prevents flex overflow on small screens */
}
.brand-logo {
  height: 48px;          /* tuned for mobile so it never gets cut */
  max-width: 100%;
  width: auto;
  display: block;
  object-fit: contain;
}
@media (min-width: 600px) {
  .brand-logo { height: 64px; }  /* larger on tablets/desktop */
}

/* Nav */
.site-nav {
  display: none;                   /* hidden by default on mobile */
  align-items: center;
  gap: 16px;
}
.site-nav a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s ease, color 0.15s ease;
}
.site-nav a:hover {
  background: rgba(255,255,255,0.12);
}

/* Hamburger */
.nav-toggle {
  appearance: none;
  border: none;
  background: transparent;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle-bar {
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 1px;
}

/* When menu is open on mobile */
.site-nav.is-open { 
  display: flex;
  position: absolute;
  right: 16px;
  top: 64px;                     /* just below header */
  flex-direction: column;
  background: #004080;
  padding: 10px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

/* Desktop layout */
@media (min-width: 840px) {
  .nav-toggle { display: none; }
  .site-nav {
    display: flex !important;    /* always visible on desktop */
    position: static;
    flex-direction: row;
    background: transparent;
    padding: 0;
    box-shadow: none;
  }
}

/* Optional: give the main container extra top padding if header is sticky */
main { padding-top: 6px; }

/* --- BASE --- */
:root{
  --brand-blue:#004080;
  --brand-blue-dark:#003366;
  --bg:#eef1f5;
  --card:#fff;
  --shadow:0 6px 20px rgba(0,0,0,0.08);
  --shadow-hover:0 10px 28px rgba(0,0,0,0.12);
}

*{box-sizing:border-box}

body{
  font-family: 'DM Sans','Calibri',Arial,sans-serif;
  background-color: var(--bg);
  color:#333;
  margin:0;
}

a{ color: var(--brand-blue); text-decoration:none; }

/* Header / footer (site chrome) */
header, footer{
  background-color: var(--brand-blue);
  color:#fff;
  padding:1rem;
  text-align:center;
}

/* --- LOGO / HEADER --- */
.logo-container{ text-align:center; margin-top:40px; }

.site-header{
  display:flex; align-items:center; justify-content:center;
  gap:12px; padding:14px 20px; background:var(--brand-blue); color:#fff;
}

.header-title{
  display:flex; align-items:center; gap:12px; margin:0; padding:0;
  background:transparent; border-radius:0;
}

.logo-img{
  height:80px; width:auto; display:inline-block; object-fit:contain; vertical-align:middle;
  border-radius:0 !important; background:transparent;
}

@media (max-width:600px){ .logo-img{ height:56px; } }

/* --- CARD CONTAINER (pretty white enclosure) --- */
.container{
  max-width: 880px;
  margin: 2rem auto;
  padding: 2rem;
  background: var(--card);
  box-shadow: var(--shadow);
  border:1px solid rgba(0,0,0,0.04);
  border-radius:14px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.container:hover{ transform: translateY(-2px); box-shadow: var(--shadow-hover); }

/* --- HERO / LANDING --- */
.hero{
  text-align:center;
  padding: 3rem 1.25rem 2.5rem;
  background: linear-gradient(180deg,
    rgba(255,255,255,0.98) 0%,
    rgba(250,250,250,0.96) 40%,
    rgba(238,241,245,0.94) 100%);
  border-radius:14px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

.hero-headline{
  font-size:2.4rem;
  line-height:1.2;
  font-weight:800;
  margin:0 0 .75rem 0;
  color:#0d1b2a;
  letter-spacing:-0.5px;
  text-shadow:0 2px 4px rgba(0,0,0,0.05);
}
@media (min-width:720px){ .hero-headline{ font-size:3rem; } }

.hero-subheadline{
  font-size:1.2rem;
  color:#333;
  max-width:720px;
  margin:0 auto 2rem;
}

.slogan{
  font-size:1.6rem;
  font-weight:700;
  margin:2rem auto 1rem;
}
.subtext{
  font-size:1rem;
  line-height:1.6;
  max-width:720px;
  margin:0 auto 2rem;
  color:#333;
}

/* --- CTA BUTTONS --- */
.cta-row{
  display:flex; gap:16px; justify-content:center; align-items:center; flex-wrap:wrap;
  margin-bottom:1.5rem;
}
.btn{
  display:inline-block;
  padding:.9rem 1.6rem;
  border-radius:10px;
  text-decoration:none;
  font-weight:700;
  border:2px solid transparent;
  transition: transform .06s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
}
.btn-primary{
  background: var(--brand-blue);
  color:#fff;
  box-shadow:0 4px 10px rgba(0,64,128,.25);
}
.btn-primary:hover{ background: var(--brand-blue-dark); transform: translateY(-1px); }

.btn-outline{
  background:#fff;
  color: var(--brand-blue);
  border-color: var(--brand-blue);
  box-shadow:0 4px 10px rgba(0,64,128,.12);
}
.btn-outline:hover{
  background: var(--brand-blue);
  color:#fff;
  transform: translateY(-1px);
}

/* Back-compat aliases (safe to keep) */
.btn-blue{ composes: btn btn-primary; } /* ignored by browsers, so duplicate rules: */
.btn-blue{ background:var(--brand-blue); color:#fff; box-shadow:0 4px 10px rgba(0,64,128,.25); }
.btn-blue:hover{ background:var(--brand-blue-dark); transform: translateY(-1px); }
.btn-blue-outline{ background:#fff; color:var(--brand-blue); border:2px solid var(--brand-blue); box-shadow:0 4px 10px rgba(0,64,128,.12); }
.btn-blue-outline:hover{ background:var(--brand-blue); color:#fff; transform: translateY(-1px); }

/* Forms */
form input, form select, form button{
  display:block; width:100%; padding:.6rem; margin-bottom:1rem;
  border:1px solid #ccc; border-radius:6px;
}
form button{ background:var(--brand-blue); color:#fff; border:none; cursor:pointer; }
form button:hover{ background:var(--brand-blue-dark); }

/* Footer note */
.footer-note{
  font-size:14px; color:#888; margin-top:60px; font-variant: small-caps;
}

/* --- Reveal-on-scroll --- */
.reveal{
  opacity:0; transform: translateY(14px);
  will-change: opacity, transform;
  transition: opacity 420ms ease-out, transform 420ms ease-out;
}
.reveal.reveal-in{ opacity:1; transform: translateY(0); }

/* common stagger points used in index.php */
.reveal[data-delay="0"]{ transition-delay: 0ms; }
.reveal[data-delay="100"]{ transition-delay:100ms; }
.reveal[data-delay="120"]{ transition-delay:120ms; }
.reveal[data-delay="180"]{ transition-delay:180ms; }
.reveal[data-delay="300"]{ transition-delay:300ms; }
.reveal[data-delay="420"]{ transition-delay:420ms; }
.reveal[data-delay="480"]{ transition-delay:480ms; }
.reveal[data-delay="540"]{ transition-delay:540ms; }
.reveal[data-delay="660"]{ transition-delay:660ms; }

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce){
  .reveal{ opacity:1 !important; transform:none !important; transition:none !important; }
}

/* ================================
   LANDING – NEW SECTIONS (2–5)
================================ */

/* Generic section wrapper */
.section {
  max-width: 980px;
  margin: 2.5rem auto;
  padding: 2rem 1.25rem;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
  border: 1px solid rgba(0,0,0,0.04);
}

/* Section titles */
.section-title {
  text-align: center;
  font-size: 1.75rem;
  font-weight: 800;
  color: #0d1b2a;
  margin: 0 0 1.25rem 0;
  letter-spacing: -0.3px;
}

/* ========== SECTION 2: ¿Cómo funciona? ========== */
.section-how .steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 1rem;
}

.step-card {
  background: #f8fafc;
  border: 1px solid rgba(0,0,0,0.05);
  border-radius: 12px;
  padding: 1rem 1rem 1.1rem;
  text-align: left;
  display: grid;
  grid-template-columns: 48px 1fr;
  align-items: start;
  gap: 12px;
  transition: transform 140ms ease, box-shadow 140ms ease;
}

.step-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(0,0,0,0.08);
}

.step-emoji {
  font-size: 28px;
  line-height: 1;
}

.step-card h3 {
  margin: 0 0 4px 0;
  font-size: 1.05rem;
  color: #0d1b2a;
}

.step-card p {
  margin: 0;
  color: #444;
}

/* CTA under steps */
.cta-under-steps {
  text-align: center;
  margin-top: 1.25rem;
}

/* Link-style CTA matching brand button */
.btn-michambita-cta {
  display: inline-block;
  padding: 0.85rem 1.5rem;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  background-color: #0066cc;
  color: #fff;
  box-shadow: 0 4px 10px rgba(0,102,204,0.22);
  transition: transform 0.06s ease, filter 0.15s ease, box-shadow 0.15s ease;
}
.btn-michambita-cta:hover {
  transform: translateY(-1px);
  filter: brightness(0.96);
  box-shadow: 0 10px 22px rgba(0,102,204,0.25);
}

/* ========== SECTION 3: Comunidad quote ========== */
.section-community {
  text-align: center;
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fc 100%);
}

.community-quote {
  margin: 0;
  font-size: 1.25rem;
  font-style: italic;
  color: #1b2a41;
}

/* ========== SECTION 4: Second CTA block ========== */
.section-cta2 {
  text-align: center;
}

.section-cta2 .cta-row {
  margin-top: 0.5rem;
}

.cta2-subtext {
  margin: 0.75rem 0 0;
  color: #2f4b7c;
  font-weight: 600;
}

/* ========== SECTION 5: Social & Legal ========== */
.section-social {
  text-align: center;
}

.social-list {
  list-style: none;
  padding: 0;
  margin: 0.25rem 0 0.75rem;
}
.social-list li {
  margin: 6px 0;
}
.social-list a {
  text-decoration: none;
  color: #004080;
}
.social-list a:hover {
  text-decoration: underline;
}

.legal-links {
  margin-top: 0.5rem;
  color: #666;
}
.legal-links a {
  color: #445;
  text-decoration: none;
}
.legal-links a:hover {
  text-decoration: underline;
}
.legal-links .dot {
  margin: 0 8px;
  opacity: 0.6;
}

/* ========== Responsive tweaks ========== */
@media (min-width: 720px) {
  .section { padding: 2.25rem 2rem; }

  .section-how .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

/* Simple alert styles */
.alert { padding: 0.85rem 1rem; border-radius: 10px; margin-bottom: 1rem; }
.alert-error { background: #ffe8e6; color: #7a1c12; border: 1px solid #f4c1bb; }

/* --- Auth Card polish --- */
.auth-card {
  max-width: 560px;
  padding: 2rem;
}

.form-title {
  margin: 0 0 .25rem 0;
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.3px;
  color: #0d1b2a;
  text-align: center;
}

.form-subtitle {
  margin: 0 0 1.25rem 0;
  text-align: center;
  color: #4a5568;
}

.auth-form .form-row { margin-bottom: 1rem; }

.auth-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
}

.auth-form input,
.auth-form select {
  width: 100%;
  padding: 0.7rem 0.8rem;
  border: 1px solid #cfd6e4;
  border-radius: 10px;
  background: #fff;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}

.auth-form input:focus,
.auth-form select:focus {
  border-color: #004080;
  box-shadow: 0 0 0 3px rgba(0,64,128,0.10);
}

.auth-form .hint {
  display: block;
  color: #6b7280;
  margin-top: 6px;
  font-size: 0.9rem;
}

.btn-block { width: 100%; }

.auth-switch {
  text-align: center;
  margin-top: .75rem;
}

.legal {
  margin-top: .75rem;
  font-size: .9rem;
  color: #6b7280;
  text-align: center;
}

/* Alerts */
.alert { padding: 0.9rem 1rem; border-radius: 12px; margin-bottom: 1rem; }
.alert-ok {
  background: #e6f7ee;
  border: 1px solid #b9e6c5;
  color: #1a6d3a;
}
.alert-error {
  background: #ffe8e6;
  border: 1px solid #f4c1bb;
  color: #7a1c12;
}
/* Honeypot field (hidden off-screen) */
.hp-field {
  position: absolute !important;
  left: -5000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}
/* Job board shell */
.jobboard-card { padding: 1.25rem 1.25rem 1.5rem; }

.jobboard-header {
  display: flex; gap: 12px; align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}

.jobboard-title { margin: 0; }

/* Filters row */
.filters {
  display: grid;
  grid-template-columns: 1fr 180px 200px auto auto;
  gap: 10px;
  margin-bottom: 12px;
}
@media (max-width: 720px) {
  .filters { grid-template-columns: 1fr 1fr; }
}

.input {
  padding: 10px 12px; border-radius: 8px; border: 1px solid #ccd6e0;
  font-size: 15px; background: #fff;
}

/* Results */
.results-count { color: #666; margin: 6px 0 14px; }

.jobs { display: grid; gap: 12px; }

.job-card {
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 12px;
  padding: 14px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.job-head { display: flex; gap: 10px; align-items: baseline; justify-content: space-between; }
.job-title { margin: 0; font-size: 1.15rem; }
.job-price { font-weight: 700; color: #0d1b2a; }

.job-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 8px; }
.pill {
  font-size: 12px; padding: 4px 8px; border-radius: 999px;
  background: #eef3fb; color: #0d3a66; border: 1px solid #d7e3f7;
}
.muted { color: #6b7280; font-size: 12px; }

.job-desc { margin: 8px 0 10px; color: #333; }

.job-actions { display: flex; gap: 10px; }

/* Pagination */
.pagination { display: flex; gap: 12px; align-items: center; justify-content: center; margin-top: 10px; }
.page-link {
  padding: 8px 12px; border-radius: 8px; border: 1px solid #ccd6e0; text-decoration: none;
}
.page-status { color: #666; }

/* --- Job view page --- */
.jobview-card { padding: 1.25rem 1.25rem 1.5rem; }

.crumbs { margin-bottom: 12px; }
.crumbs a { color: #004080; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }

.jobview-head {
  display: flex; gap: 12px; align-items: baseline; justify-content: space-between;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  padding-bottom: 8px; margin-bottom: 10px;
}
.jobview-title { margin: 0; font-size: 1.35rem; }
.jobview-price { font-weight: 800; color: #0d1b2a; }

.jobview-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 12px; }
.jobview-body h3 { margin: 0 0 6px; }
.jobview-body p { margin: 0; white-space: pre-wrap; }

.jobview-actions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }

.inline-form { display: inline; }

.alert { padding: 0.85rem 1rem; border-radius: 8px; margin: 0.75rem 0; }
.alert-error { background: #fde8e8; color: #9b1c1c; border: 1px solid #f8c7c7; }
.alert-ok    { background: #e7f8ef; color: #0f5132; border: 1px solid #bde5cf; }

/* Pagination Bar (compact + mobile friendly) */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 24px 0;
  font-family: inherit;
}

.pagination .page-link,
.pagination .page-ellipsis {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.95rem;
  text-decoration: none;
  color: #2563eb; /* your btn-blue color */
  border: 1px solid #2563eb;
  transition: all 0.15s ease;
}

.pagination .page-link:hover {
  background: #2563eb;
  color: white;
}

.pagination .page-link.current {
  background: #2563eb;
  color: #fff;
  pointer-events: none;
  border-color: #2563eb;
}

.pagination .page-link.disabled {
  color: #999;
  border-color: #ccc;
  background: #f9f9f9;
  pointer-events: none;
}

.pagination .page-ellipsis {
  border: none;
  color: #999;
  pointer-events: none;
}

.profile-rating {
  margin-top: 0.25rem;
  font-size: 0.95rem;
}

.profile-rating .stars {
  font-weight: 600;
  margin-right: 4px;
}
.profile-rating {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  border-radius: 8px;
  background: #f5fafc;
}

.profile-rating h3 {
  margin-top: 0;
  margin-bottom: 0.25rem;
}

.profile-reviews {
  margin-top: 1.5rem;
}

.review-card {
  border-radius: 8px;
  border: 1px solid #e3e7ec;
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  background: #fff;
}

.review-head {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
  margin-bottom: 0.25rem;
}

.review-stars {
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
}

.review-comment {
  margin: 0 0 0.4rem 0;
}

.review-meta {
  font-size: 0.8rem;
}

.badge-top {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  background: #ffe9a8;
  color: #7a4b00;
  font-size: 0.8rem;
  font-weight: 600;
}
