:root {
  /* Professional color palette */
  --color-primary: #007bff;
  --color-primary-dark: #0056b3;
  --color-secondary: #6c757d;
  --color-success: #28a745;
  --color-warning: #ffc107;
  --color-danger: #dc3545;
  --color-info: #17a2b8;
  
  /* Surface colors */
  --color-surface: #ffffff;
  --color-surface-alt: #f8f9fa;
  --color-surface-elevated: #ffffff;
  
  /* Text colors */
  --color-text: #495057;
  --color-text-muted: #6c757d;
  --color-text-light: #adb5bd;
  
  /* Border colors */
  --color-border: #dee2e6;
  --color-border-light: #e9ecef;
  
  /* Background colors */
  --color-bg: #f8f9fa;
  --color-bg-light: #ffffff;
  
  /* Global border radius */
  --radius: 8px;
  --radius-sm: 6px;
  --radius-lg: 12px;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
}
/* === make the page use all available viewport space === */
html, body {
  /* height: 100%; */
}

body {
  min-height: 100svh;           /* use 100vh if you prefer */
  display: flex;
  flex-direction: column;       /* nav | main | footer vertical stack */
}

/* the content area should expand and take the leftover space */
main {
  flex: 1 1 auto;
  min-height: max-content;
  height: 100%;
}

/* (optional) ensure footer doesn’t stick mid‑page if content is short */
.site-footer {
  flex-shrink: 0;
}


/* base.css */
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
}

/* ── NAV ── */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.9) 0%, rgba(99, 102, 241, 0.9) 50%, rgba(139, 92, 246, 0.9) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.logo-img {
  height: 36px;
  object-fit: contain;
  padding: 0;
  filter: brightness(1.1);
}

/* ── NAV ACTIONS CONTAINER ── */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* ── SHARED BUTTON STYLES ── */
.nav-actions button {
    gap: 0.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius);
    color: white;
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-direction: row;
    width: auto;
    min-width: 100px;
    backdrop-filter: blur(10px);
}

.btn-icon {
  width: auto;
  padding: 0.4rem;
  background: transparent;
  color: white;

      gap: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0 solid var(--color-secondary);
    border-radius: var(--radius);
    color: ghostwhite;
    padding: 0.25rem 0.75rem;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    flex-direction: row;
    width: 100%;
}
body > nav > div.nav-actions > a:nth-child(4) > button {
  height: 2.5rem;
}

/* Hover/focus states */
.nav-actions button:hover,
.nav-actions button:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
  outline: none;
}

/* ── ICON‑ONLY UPLOAD BUTTON ── */
/* Assumes you’re using an <i class="fa fa-upload"></i> inside the button */
.btn-upload {
  /* width: 2.5rem;             square */
  height: 2.5rem;
  padding: 0;                /* remove text padding */
  font-size: 1.2rem;         /* larger icon */
}

/* If you need extra breathing room around the icon, you can override: */
/* .btn-upload { padding: 0.25rem; } */

/* ── TEXT‑ONLY SIGN IN BUTTON ── */
.btn-signin {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  box-shadow: var(--shadow);
}

/* On hover, invert back to transparent for a stylistic effect */
.btn-signin:hover,
.btn-signin:focus {
  background: linear-gradient(135deg, var(--color-primary-dark) 0%, #003d82 100%);
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}

/* ── MAIN FOOTER ── */
.site-footer {
  background: linear-gradient(135deg, var(--color-surface-alt) 0%, var(--color-border-light) 100%);
  border-top: 1px solid var(--color-border);
  padding: 2rem 2rem 1.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.footer-links a,
.footer-info a {
  color: var(--color-text);
  text-decoration: none;
  margin: 0 0.5rem;
  transition: color 0.3s ease;
}

.footer-links a:hover,
.footer-info a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

/* ── MODAL BACKDROP ── */
.modal-backdrop {
  position: fixed;
  inset: 0;                       /* shorthand for top:0; right:0; bottom:0; left:0; */
  background: rgba(0,0,0,0.5);
  z-index: 9999;
}

/* ── MODAL WINDOW (fixed positioning retained!) ── */

.modal[hidden] {
  display: none;
}

/* ── MODAL CLOSE BUTTON ── */
.modal-close {
  position: absolute;
  top: 0.25rem;                   /* ↓ tighter to corner */
  right: 0.5rem;
  background: transparent;
  border: none;
  font-size: 1.25rem;
  cursor: pointer;
}
.about-values {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  text-align: center;
  margin: 2rem 0;
}
.value h3 {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}
.value p {
  margin: 0;
  color: #4b5563;
  line-height: 1.4;
}
.about-section {
  margin: 4rem 0;
}
.about-hero {
  padding: 4rem 0;      /* less than current */
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
}
.about-cards,
.about-values {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}
.about-cards .card, .about-values .value {
background: #ffffff;
    padding: 1.5rem;
    border-radius: 14px;
    text-align: center;
    /* box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05); */
    border: 1px solid #eee;
}
h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}
.lead {
  font-size: 1.125rem;
  color: #ffffff;
  line-height: 1.6;
  max-width: 600px;
  margin: 1rem auto 2rem;
}
p {
  line-height: 1.6;
  /* color: #444; */
}
.about-section + .about-section {
  border-top: 1px solid #eee;
  padding-top: 3rem;
  width: 86%;
}
.about-cta {
  text-align: center;
  margin: 4rem 0;
}
.about-cta a {
  margin: 0 0.5rem;
}
.SuID-field { position:absolute; left:-9999px; width:1px; height:1px; overflow:hidden; }


@media (max-width: 900px) {
  nav {
    padding: 0.75rem 1rem;
  }
  
  .nav-actions {
    gap: 0.5rem;
  }
  
  .nav-actions button {
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
    min-width: auto;
  }
  
  .btn-upload span {
    display: none;
  }
  
  .btn-upload i {
    font-size: 1rem;
  }
  
  .logo-img {
    height: 28px;
  }
}
/* 1) Give a definite height chain */
html, body { height: 100%; }               /* ← restore this */
body {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
main {
  flex: 1 1 auto;
  /* min-height: 0;                           allow children to size */
  height: auto;                            /* no 100% here */
}

/* 2) Split layout fills main */
.app-container { height: 100%; min-height: 0; }
#splitContainer {
  display: grid;
  grid-template-columns: 74vw 6px 1fr;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

/* Mobile layout - allow JavaScript to override */
@media (max-width: 900px) {
  #splitContainer {
    display: flex;
    flex-direction: column;
    grid-template-columns: none;
  }
}

/* 3) Children can shrink; inner content scrolls */
.viewer-panel, .side-panel { min-height: 0; }
.tab-content {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden; /* Let child containers handle their own scrolling */
  max-height: none;                        /* remove the 789px cap */
}
/* ===== Modal stacking + click-through fixes ===== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.4);
  z-index: 1000;                 /* below modal, above page */
}
.modal-backdrop[hidden] { display: none !important; }

.modal {
  position: relative;            /* positioning context for overlays */
  z-index: 1001;                 /* above backdrop */
  background: var(--color-surface, #fff);
  border-radius: 12px;
  max-width: 640px;
  width: min(92vw, 640px);
  max-height: min(90vh, 800px);
  overflow: auto;
  box-shadow: 0 12px 40px rgba(0,0,0,.25);
  padding: 0.5rem;                /* ↓ very small padding */
  border: 2px solid #e5e7eb;
}

/* Make the X always clickable */
.modal-close {
  position: absolute;
  top: .5rem;
  right: .5rem;
  z-index: 1002;                 /* above everything inside modal */
  background: none;
  border: 0;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

/* Busy overlay should block clicks only when visible */
.auth-busy-global {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,.6);
  z-index: 1001;                 /* under .modal-close so X still works */
  pointer-events: auto;          /* blocks form while busy */
}
.auth-busy-global[hidden] {
  display: none !important;
  pointer-events: none !important;
}

/* Your global toast/overlay must never steal clicks */
#messages-overlay {
  position: fixed;
  inset: 0;
  z-index: 1;                    /* far below modal */
  pointer-events: none;          /* NEVER capture clicks */
}

.auth-perk {
  margin:0;
  font-size: .95rem;
  line-height: 1.4;
  background: #f6f7fb;
  border: 1px solid #e6e8f0;
  border-radius: 10px;
  padding: .75rem .9rem;
  text-align: center;
}

@media (max-width: 900px) {
  .logo-img {
    height: 26px;
  }
  nav {
    padding: 6px;
  }
  .btn-upload i {
    font-size: 23px;
  }
  .nav-actions button {
    font-size: 23px;
  }
  .nav-actions span {
    font-size: 0;
  }
  .nav-actions {
    gap: 6px;
  }
}

/* === Nice, on-brand modal (no HTML changes) =============================== */
:root {
  --brand-500: #5a2ca0;
  --brand-600: #4c238e;
  --ink-900: #111827;
  --ink-600: #4b5563;
  --line: #e5e7eb;
}

/* Backdrop */
.modal-backdrop[hidden] { display: none !important; }
.modal-backdrop {
  position: fixed; inset: 0;
  display: grid; place-items: center;
  background: rgba(17, 12, 28, .55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 4000;
}

/* Dialog */
.modal-backdrop .modal {
}

/* Brand accent bar */
.modal-backdrop .modal::before {
  /* content: "";
  position: absolute; inset: 0 0 auto 0; height: 4px;
  background: linear-gradient(90deg, var(--brand-600), var(--brand-500)); */
}

/* Close button */
.modal-backdrop .modal-close {
  position: absolute; top: 10px; right: 10px;
  width: 36px; height: 36px; border-radius: 8px;
  border: 0; background: none; cursor: pointer;
  font-size: 24px; line-height: 1; color: var(--ink-600);
}
.modal-backdrop .modal-close:hover { background: rgba(90,44,160,.08); color: var(--brand-600); }
.modal-backdrop .modal-close:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--brand-500) 35%, transparent);
  outline-offset: 2px;
}

/* Headings inside injected forms */
.modal h2 {
  margin: 0 0 8px;
  font-size: 28px; font-weight: 800; letter-spacing: -.01em; color: var(--ink-900);
}

/* Form groups */
.modal .form-group { margin: 10px 0 8px; }
.modal label { display: block; font-weight: 700; color: var(--ink-900); margin-bottom: 6px; }
.modal input[type="email"],
.modal input[type="password"],
.modal input[type="text"],
.modal input[type="password1"],
.modal input[type="password2"] {
  width: 100%; height: 44px; border-radius: 10px;
  border: 1px solid var(--line);
  background: #f8fafc;
  padding: 0 12px;
}
.modal input:focus {
  outline: none;
  border-color: color-mix(in srgb, var(--brand-500) 55%, var(--line));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-500) 22%, transparent);
}

/* Primary submit buttons in these modals */
.modal .auth-form button[type="submit"] {
  width: 100%; height: 46px; border-radius: 10px;
  border: 0; color: #fff; font-weight: 700;
  background: linear-gradient(90deg, var(--brand-600), var(--brand-500));
  box-shadow: 0 6px 16px rgba(90,44,160,.25);
  margin-top: 12px;
}
.modal .auth-form button[type="submit"]:hover { filter: brightness(.97); }
.modal .auth-form button[type="submit"]:active { transform: translateY(1px); }
.modal .auth-form button[type="submit"]:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--brand-500) 35%, transparent);
  outline-offset: 2px;
}

/* Removed conflicting CSS for "or" separator - now handled in account.css */
/* Removed conflicting ::before and ::after pseudo-elements for "or" separator */

/* Social logins list */
.modal ul.social-logins { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.modal ul.social-logins li a {
  display: flex; align-items: center; gap: 12px; height: 46px; border-radius: 10px;
  text-decoration: none; font-weight: 600;
  padding: 0 12px;
   color: var(--ink-900); border: 1px solid var(--line);
}
.modal ul.social-logins li a .social-icon { width: 22px; height: 22px; display: inline-block; }

/* Provider treatments */
.modal a.provider-facebook { background: #1877f2; border-color: #1877f2; color: #fff; box-shadow: 0 4px 12px rgba(24,119,242,.25); }
.modal a.provider-facebook:hover { filter: brightness(.96); }
.modal a.provider-google { background: #fff; border-color: var(--line); color: #1f2937; }
.modal a.provider-google:hover { background: #f9fafb; }

/* Footer text inside modal */
.modal .auth-footer { margin-top: 12px; text-align: center; color: var(--ink-600); }
.modal .auth-footer a { color: var(--brand-500); font-weight: 600; text-decoration: none; }
.modal .auth-footer a:hover { text-decoration: underline; }

/* Busy overlay + spinner (already in your form HTML) */
.modal .auth-busy[hidden] { display: none !important; }
.modal .auth-busy {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: rgba(255,255,255,.72); z-index: 2;
}
.modal .auth-spinner {
  width: 28px; height: 28px; border-radius: 50%;
  border: 3px solid #d1d5db; border-top-color: var(--brand-500);
  animation: auth-spin .8s linear infinite;
}
@keyframes authspin { to { transform: rotate(360deg); } }

@media (max-width: 900px) {
  /* keep spans hidden for all buttons */
  .nav-actions span {
    font-size: 0;
  }

  /* but restore text ONLY for the Upload button */
  .mobileuploadbtn span {
    display: inline;
    font-size: 0.8rem;
    margin-left: 4px;
  }

  /* give Upload its own background */
  .nav-actions .mobileuploadbtn {
    background: #ffffff !important;
    color: #000000 !important;
    border: none !important;
    padding: 0.5rem 1rem !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  }
  
  .nav-actions .mobileuploadbtn:hover {
    background: #f8f9fa !important;
    color: #000000 !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
  }
}


@media (prefers-color-scheme: dark) {
.site-footer {
    background: #595959;
    color: #e5e5e5;
}
nav {
    background-image: linear-gradient(135deg, rgba(59, 130, 246, 0.9) 0%, rgba(99, 102, 241, 0.9) 50%, rgba(139, 92, 246, 0.9) 100%);
}
  .auth-perk {

    color: black;
}
.site-footer {
  border-top: 1px solid #4d4d4d85;
}
.about-section + .about-section {
    border-top: 2px solid #9696964a;
    padding-top: 3rem;
}
.modal {
    background: #4a00dbde;
    border: 3px solid #9991a696;
}
.modal h2 {
    color: #f5f5f5;
}
.modal-backdrop .modal-close {
    color: #bcbcbcd6;
}
.modal input[type="email"], .modal input[type="password"], .modal input[type="text"], .modal input[type="password1"], .modal input[type="password2"] {
    border: 1px solid #ffffff45;
}
.modal ul.social-logins li a {
    border: 1px solid #ffffff12;
}
.modal .auth-footer {
    color: #f3f3f3;
}
.modal .auth-footer a {
    color: #fffd00;
}
.jargon.k-sent {
    background: rgb(224 236 255);
    box-shadow: inset 0 -1px 0 rgb(46 128 255);
}
.modal form + p {
    color: #deddff;
}
.security-sub a {
    color: #fffd00;
}
}


/* Default (desktop): logotype */
.logo-img {
  content: url("/static/images/logotype.07dab8e809be.png");
  height: 32px;
  object-fit: contain;
  padding: 6px 4px 2px 8px;
}

/* Mobile: switch to logomark */
@media (max-width: 900px) {
  .logo-img {
    content: url("/static/images/logo.5dbd41d4fef8.png"); /* your X:\UNJARGON\static\images\logo.png */
    height: 28px; /* adjust size as needed */
  }
}


.nav-actions button:hover, .nav-actions button:focus {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
    box-shadow: var(--shadow);
    outline: none;
}
  .nav-actions .mobileuploadbtn {
        background: #ffffff !important;
        color: #000000 !important;
        border: none !important;
        padding: 0.5rem 1rem !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    /* Layout for the logo area */
.logo { display: flex; align-items: center; }
.logo-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    margin-right: 5px;
    flex-direction: column-reverse;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 8px 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}
/* Title is hidden by default (desktop shows the logotype image) */
.logo-title {
    display: none;
    font-weight: 800;
    font-size: 8px;
    letter-spacing: 0.02em;
    color: #ffffff;
    line-height: 1;
}
.logo-img {
    height: 28px;
    object-fit: contain;
    padding: 0;
    filter: brightness(1.2);
}
/* You already swap the image to the logomark on mobile.
   Also show the text next to it on mobile. */
@media (max-width: 900px) {
  .logo-title { display: inline-block; }
  .logo-img { height: 28px; }     /* you already set this below; safe to keep */
  .logo-link { padding: 5px 4px; }
}

/* Logo hover effect */
.logo-link:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
}

/* (Optional) Dark mode—title stays readable */
@media (prefers-color-scheme: dark) {
  .logo-title { color: #fff; }
}
