/* css/main.css */
/* ═══════════════════════════════════════════
   ApexVault — Black / White / Blue / Grey / Charcoal
   Palette:
     --bg        #FFFFFF  White
     --primary   #2A2E35  Charcoal (buttons, CTAs, accents)
     --pine      #2563EB  Electric Blue (dark headers/hero only)
     --earth     #2A2E35  Charcoal (alias, same as primary now)
     --earth-lt  #F3F4F6  Light Grey (card tint)
     --secondary #2563EB  Electric Blue
     --border    #E5E7EB  Grey border
     --muted     #6B7280  Grey muted text
═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Inter:wght@300;400;500&display=swap');

:root {
  --bg:          #FFFFFF;
  --bg-deep:     #F3F4F6;
  --primary:     #2A2E35;
  --primary-hv:  #3D424B;
  --pine:        #2563EB;
  --pine-hv:     #1D4ED8;
  --earth:       #2A2E35;
  --earth-lt:    #F3F4F6;
  --card-bg:     #FFFFFF;
  --secondary:   #2563EB;
  --border:      #E5E7EB;
  --border-dark: #D1D5DB;
  --text-main:   #111827;
  --text-muted:  #6B7280;
  --text-white:  #FFFFFF;
  --radius:      20px;
  --radius-sm:   12px;
  --radius-xs:   8px;
  --shadow:      0 2px 16px rgba(17,24,39,0.06);
  --shadow-lg:   0 8px 40px rgba(37,99,235,0.15);
  --transition:  200ms cubic-bezier(0.4,0,0.2,1);
  --nav-height:  72px;
}

*, *::before, *::after { box-sizing:border-box; margin:0; padding:0; }
html { -webkit-font-smoothing:antialiased; scroll-behavior:smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text-main);
  min-height: 100vh;
  padding-bottom: var(--nav-height);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--primary);
}

a { text-decoration: none; color: inherit; }
img { max-width:100%; display:block; }

/* ── BUTTONS ─────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: var(--text-white);
}
.btn-primary:hover {
  background: var(--primary-hv);
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}
.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: var(--text-white);
}

.btn-ghost {
  background: var(--earth-lt);
  color: var(--primary);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: #E5E7EB; }

.btn-earth {
  background: var(--primary);
  color: var(--text-white);
  font-weight: 700;
}
.btn-earth:hover { background: var(--primary-hv); }

.btn-full  { width: 100%; }
.btn-sm    { padding: 9px 16px; font-size: 12px; }
.btn-lg    { padding: 17px 36px; font-size: 15px; }

/* ── CARDS ───────────────────────────── */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
}

.stat-card {
  background: var(--earth-lt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
}

/* ── FORM ELEMENTS ───────────────────── */
.form-group { display:flex; flex-direction:column; gap:6px; margin-bottom:16px; }

.form-label {
  font-size: 12px;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  color: var(--primary);
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.form-input {
  width: 100%;
  padding: 13px 15px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--text-main);
  background: var(--card-bg);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}
.form-input::placeholder { color: var(--text-muted); }

select.form-input { cursor: pointer; }
textarea.form-input { resize: vertical; min-height: 80px; }

/* ── BADGES ──────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 0.3px;
}
.badge-active    { background: #DCFCE7; color: #16A34A; }
.badge-pending   { background: #FEF3C7; color: #D97706; }
.badge-approved  { background: #DCFCE7; color: #16A34A; }
.badge-declined  { background: #FEE2E2; color: #DC2626; }
.badge-completed { background: #E0E7FF; color: #4F46E5; }
.badge-confirmed { background: #DCFCE7; color: #16A34A; }
.badge-failed    { background: #FEE2E2; color: #DC2626; }

/* ── DIVIDER ─────────────────────────── */
.divider {
  display:flex; align-items:center; gap:12px;
  color:var(--text-muted); font-size:13px; margin:20px 0;
}
.divider::before, .divider::after {
  content:''; flex:1; height:1px; background:var(--border);
}

/* ── PAGE WRAPPER ────────────────────── */
.page-content { max-width:480px; margin:0 auto; padding:24px 16px; }

.page-header {
  display:flex; align-items:center; gap:12px; margin-bottom:24px;
}
.page-header h1 { font-size:21px; }
.back-btn {
  width:40px; height:40px;
  display:flex; align-items:center; justify-content:center;
  border-radius:50%;
  background:var(--earth-lt);
  border:1px solid var(--border);
  cursor:pointer;
  transition:background var(--transition);
  flex-shrink:0;
}
.back-btn:hover { background:#E5E7EB; }

/* ── BOTTOM NAV ──────────────────────── */
.bottom-nav {
  position:fixed; bottom:0; left:0; right:0;
  height:var(--nav-height);
  background:var(--card-bg);
  border-top:1.5px solid var(--border);
  display:flex; align-items:center; justify-content:space-around;
  z-index:100; padding:0 8px;
  box-shadow: 0 -4px 20px rgba(17,24,39,0.08);
}
.bottom-nav a {
  display:flex; flex-direction:column; align-items:center; gap:4px;
  padding:8px 10px;
  border-radius:var(--radius-xs);
  color:var(--text-muted);
  font-size:10px; font-weight:700;
  font-family:'Montserrat',sans-serif;
  letter-spacing:0.3px;
  transition:all var(--transition);
  min-width:52px; cursor:pointer;
}
.bottom-nav a:hover,
.bottom-nav a.active { color:var(--primary); }
.bottom-nav a.active svg { stroke:var(--primary); }
.bottom-nav svg { stroke:currentColor; transition:stroke var(--transition); }

/* ── SECTION TITLE ───────────────────── */
.section-title {
  font-size:11px; font-weight:800;
  font-family:'Montserrat',sans-serif;
  color:var(--text-muted);
  letter-spacing:1px;
  text-transform:uppercase;
  margin-bottom:14px;
}

/* ── UTILITY ─────────────────────────── */
.text-center { text-align:center; }
.text-muted  { color:var(--text-muted); font-size:13px; }
.text-pine   { color:var(--pine); }
.text-earth  { color:var(--primary); }
.mt-8  { margin-top:8px; }
.mt-16 { margin-top:16px; }
.mt-24 { margin-top:24px; }
.mb-16 { margin-bottom:16px; }
.mb-24 { margin-bottom:24px; }
.flex  { display:flex; }
.flex-col { flex-direction:column; }
.items-center { align-items:center; }
.justify-between { justify-content:space-between; }
.gap-8  { gap:8px; }
.gap-12 { gap:12px; }
.gap-16 { gap:16px; }
.w-full { width:100%; }
.grid-2 { display:grid; grid-template-columns:1fr 1fr; gap:12px; }

/* ── MODAL (shared across all pages) ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(17,24,39,0.5);
  display: flex; align-items: center; justify-content: center;
  z-index: 200;
  backdrop-filter: blur(3px);
}
.modal-overlay.hidden,
.modal-overlay[style*="display:none"],
.modal-overlay[style*="display: none"] { display: none !important; }

.modal {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 28px;
  width: 92%;
  max-width: 440px;
  border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(17,24,39,0.15);
  animation: modalIn 0.22s ease;
}
@keyframes modalIn {
  from { opacity:0; transform:scale(0.95) translateY(10px); }
  to   { opacity:1; transform:scale(1) translateY(0); }
}
.modal-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800; font-size: 17px;
  color: var(--primary); margin-bottom: 16px;
}
.modal-actions {
  display: flex; gap: 10px;
  justify-content: flex-end;
  margin-top: 22px;
}

/* ── INFO BOX ────────────────────────── */
.info-box {
  background:var(--earth-lt);
  border:1px solid var(--border);
  border-left:4px solid var(--pine);
  border-radius:var(--radius-sm);
  padding:13px 16px;
  font-size:13px;
  color:var(--primary);
  line-height:1.5;
}

@media (prefers-reduced-motion:reduce) {
  *, *::before, *::after {
    animation-duration:0.01ms !important;
    transition-duration:0.01ms !important;
  }
}


/* ===== LANGUAGE WIDGET — SQUARE STYLE ===== */
.lang-widget {
    position: fixed;
    left: 16px;
    bottom: 20px;
    z-index: 99999;
    font-family: 'Segoe UI', sans-serif;
}

.lang-current {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #1a202c;
    color: #fff;
    padding: 13px 18px;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 6px 24px rgba(0,0,0,0.35);
    font-weight: 700;
    font-size: 16px;
    min-width: 130px;
    border: 2px solid rgba(255,255,255,0.08);
    user-select: none;
    transition: background 0.2s;
}

.lang-current:hover {
    background: #2d3748;
}

.lang-current img {
    width: 28px;
    height: 19px;
    object-fit: cover;
    border-radius: 3px;
    flex-shrink: 0;
}

.lang-caret {
    margin-left: auto;
    font-size: 10px;
    opacity: 0.6;
    transition: transform 0.2s;
}

.lang-widget.open .lang-caret {
    transform: rotate(180deg);
}

/* DROPDOWN — opens upward */
.lang-dropdown {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 0;
    background: #1a202c;
    border-radius: 12px;
    overflow-y: auto;
    max-height: 380px;
    width: 220px;
    display: none;
    box-shadow: 0 -8px 32px rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.08);
    scrollbar-width: thin;
    scrollbar-color: #4a5568 transparent;
}

.lang-dropdown::-webkit-scrollbar { width: 5px; }
.lang-dropdown::-webkit-scrollbar-thumb { background: #4a5568; border-radius: 10px; }

.lang-dropdown.open {
    display: block;
    animation: dropUp 0.18s ease-out;
}

@keyframes dropUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.lang-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #e2e8f0;
    transition: background 0.15s;
    border-radius: 0;
}

.lang-item:first-child { border-radius: 12px 12px 0 0; }
.lang-item:last-child  { border-radius: 0 0 12px 12px; }

.lang-item:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.lang-item img {
    width: 26px;
    height: 17px;
    object-fit: cover;
    border-radius: 3px;
    flex-shrink: 0;
}

/* HIDE GOOGLE UI COMPLETELY */
#google_translate_element {
    display: none !important;
    visibility: hidden !important;
}

.goog-te-banner-frame,
.goog-te-banner-frame.skiptranslate,
.skiptranslate,
#goog-gt-tt,
.goog-tooltip,
.goog-tooltip-content,
.goog-te-balloon-frame,
.goog-te-menu-frame,
.goog-te-spinner-pos {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
    height: 0 !important;
    overflow: hidden !important;
}

body.translated-ltr,
body.translated-rtl {
    margin-top: 0 !important;
    top: 0 !important;
}