/* ==================================================================
   ORION - Yopass theme  -  secure.orion-quant.com
   ------------------------------------------------------------------
   A drop-in stylesheet that re-skins a self-hosted Yopass instance
   (github.com/jhaals/yopass - React + Material-UI v5) into the ORION
   forest / white / brass system, WITHOUT forking upstream.

   HOW IT STAYS MAINTAINABLE
   - We never touch Yopass source. This file is injected at the edge
     (nginx sub_filter - see nginx.conf.example) so Yopass can be
     upgraded freely; only this stylesheet + the logo assets are ours.
   - It targets STABLE MUI semantic class names (.MuiButton-root,
     .MuiPaper-root, ...), never the hashed emotion classes (.css-xxxx)
     that change every build.
   - All ORION values live in the :root block below - change them in
     one place.
   ================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital@0;1&family=GFS+Didot&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --o-ink:       #1B3A2F;   /* forest ground */
  --o-ink-2:     #14302A;   /* darker forest - app bar, backdrop */
  --o-ink-3:     #22483B;   /* raised - the card */
  --o-line:      #3D5E51;   /* hairline */
  --o-white:     #FFFFFF;   /* foreground */
  --o-white-2:   #E8EDE9;   /* secondary text */
  --o-muted:     #A0B2A8;   /* meta */
  --o-gold:      #D6B872;   /* brass accent */
  --o-gold-2:    #E5C589;   /* cream-brass - italics */
  --o-wash:      rgba(214,184,114,0.12);
  --o-amber:     #C9A55F;   /* caution */
  --o-sage:      #8FB893;   /* success */

  --o-display: 'GFS Didot','Didot',Georgia,serif;
  --o-italic:  'Cormorant Garamond',Georgia,serif;
  --o-body:    'Inter',system-ui,sans-serif;
  --o-mono:    'JetBrains Mono',ui-monospace,monospace;
}

/* -- Ground ------------------------------------------------------- */
html, body, #root { background: var(--o-ink-2) !important; }
body { font-family: var(--o-body) !important; color: var(--o-white-2) !important; }

/* -- App bar / header --------------------------------------------- */
.MuiAppBar-root {
  background: var(--o-ink-2) !important;
  color: var(--o-white) !important;
  box-shadow: none !important;
  border-bottom: 1px solid var(--o-line) !important;
  background-image: none !important;
}
.MuiToolbar-root { min-height: 68px !important; }
/* hide the stock Yopass wordmark text; the ORION lockup is injected (see welcome-banner.html) */
.MuiAppBar-root .MuiTypography-root { font-family: var(--o-display) !important; letter-spacing: 4px !important; }

/* -- Card / surfaces ---------------------------------------------- */
.MuiPaper-root, .MuiCard-root {
  background: var(--o-ink-3) !important;
  color: var(--o-white-2) !important;
  border: 1px solid var(--o-line) !important;
  border-radius: 0 !important;              /* square house */
  box-shadow: 0 16px 40px -28px rgba(0,0,0,0.6) !important;
  background-image: none !important;
}
.MuiPaper-root { border-top: 1px solid var(--o-gold) !important; }  /* brass keyline */

/* -- Typography --------------------------------------------------- */
.MuiTypography-root { font-family: var(--o-body) !important; color: var(--o-white-2) !important; }
.MuiTypography-h1, .MuiTypography-h2, .MuiTypography-h3,
.MuiTypography-h4, .MuiTypography-h5, .MuiTypography-h6 {
  font-family: var(--o-display) !important;
  font-weight: 400 !important;
  color: var(--o-white) !important;
  letter-spacing: -0.005em !important;
}
a, .MuiLink-root { color: var(--o-gold) !important; text-decoration: none !important; }
a:hover, .MuiLink-root:hover { color: var(--o-gold-2) !important; }

/* -- Text fields (the secret textarea + inputs) ------------------- */
.MuiInputLabel-root, .MuiFormLabel-root {
  font-family: var(--o-mono) !important;
  font-size: 11px !important; letter-spacing: 0.18em !important; text-transform: uppercase !important;
  color: var(--o-gold-2) !important;
}
.MuiInputLabel-root.Mui-focused { color: var(--o-gold) !important; }
.MuiOutlinedInput-root {
  background: rgba(0,0,0,0.14) !important;
  border-radius: 0 !important;
  color: var(--o-white) !important;
  font-family: var(--o-mono) !important;
}
.MuiInputBase-input, textarea.MuiInputBase-input {
  color: var(--o-white) !important;
  font-family: var(--o-mono) !important;
  font-size: 13px !important;
}
.MuiOutlinedInput-notchedOutline { border-color: var(--o-line) !important; border-radius: 0 !important; }
.MuiOutlinedInput-root:hover .MuiOutlinedInput-notchedOutline { border-color: var(--o-gold-2) !important; }
.MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline { border-color: var(--o-gold) !important; border-width: 1px !important; }
::placeholder { color: var(--o-muted) !important; opacity: 1 !important; }

/* -- Buttons ------------------------------------------------------ */
.MuiButton-root {
  font-family: var(--o-mono) !important;
  font-weight: 500 !important;
  letter-spacing: 0.24em !important;
  text-transform: uppercase !important;
  font-size: 11px !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 12px 24px !important;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease !important;
}
/* primary "encrypt" action - brass outline, brass wash on hover (never a brass fill) */
.MuiButton-contained, .MuiButton-containedPrimary, .MuiButton-containedSecondary {
  background: transparent !important;
  color: var(--o-gold) !important;
  border: 1px solid var(--o-gold) !important;
}
.MuiButton-contained:hover, .MuiButton-containedPrimary:hover, .MuiButton-containedSecondary:hover {
  background: var(--o-wash) !important;
}
.MuiButton-outlined, .MuiButton-text {
  background: transparent !important;
  color: var(--o-white) !important;
  border: 1px solid var(--o-line) !important;
}
.MuiButton-outlined:hover, .MuiButton-text:hover { background: var(--o-wash) !important; border-color: var(--o-gold) !important; }
.MuiButton-root.Mui-disabled { opacity: 0.4 !important; color: var(--o-muted) !important; border-color: var(--o-line) !important; }

/* -- Radios / expiry options / checkboxes ------------------------- */
.MuiRadio-root, .MuiCheckbox-root { color: var(--o-line) !important; }
.MuiRadio-root.Mui-checked, .MuiCheckbox-root.Mui-checked { color: var(--o-gold) !important; }
.MuiFormControlLabel-label { font-family: var(--o-body) !important; color: var(--o-white-2) !important; font-size: 13px !important; }
.MuiSelect-select { font-family: var(--o-mono) !important; color: var(--o-white) !important; }

/* -- Alerts (decrypted secret, errors, notices) ------------------- */
.MuiAlert-root { border-radius: 0 !important; font-family: var(--o-body) !important; background: var(--o-ink) !important; border: 1px solid var(--o-line) !important; color: var(--o-white-2) !important; }
.MuiAlert-standardSuccess, .MuiAlert-filledSuccess { border-left: 2px solid var(--o-sage) !important; }
.MuiAlert-standardError, .MuiAlert-filledError { border-left: 2px solid #A85440 !important; }
.MuiAlert-standardInfo, .MuiAlert-standardWarning { border-left: 2px solid var(--o-amber) !important; }
.MuiAlert-icon { color: var(--o-gold) !important; }

/* -- Snackbar / tooltip ------------------------------------------- */
.MuiSnackbarContent-root, .MuiTooltip-tooltip { background: var(--o-ink-3) !important; color: var(--o-white) !important; border: 1px solid var(--o-line) !important; border-radius: 0 !important; font-family: var(--o-mono) !important; }

/* -- Selection ---------------------------------------------------- */
::selection { background: var(--o-wash) !important; color: var(--o-white) !important; }

/* -- The injected ORION welcome block (see welcome-banner.html) --- */
.orion-band { max-width: 720px; margin: 28px auto 0; padding: 0 16px; }
.orion-lockup { display: inline-flex; align-items: center; gap: 12px; color: var(--o-white); }
.orion-logo { height: 30px; width: auto; display: block; }
.orion-belt { display: inline-flex; align-items: flex-end; gap: 5px; }
.orion-belt i { width: 5px; height: 5px; border-radius: 50%; background: var(--o-gold); display: block; }
.orion-belt i:nth-child(2) { transform: translateY(-4px); }
.orion-belt i:nth-child(3) { transform: translateY(-8px); }
.orion-lockup b { font-family: var(--o-display); font-size: 24px; font-weight: 400; letter-spacing: 8px; padding-left: 8px; }
.orion-eyebrow { font-family: var(--o-mono); font-size: 10px; letter-spacing: 0.30em; text-transform: uppercase; color: var(--o-gold); margin: 22px 0 12px; }
.orion-title { font-family: var(--o-display); font-size: 34px; line-height: 1.06; color: var(--o-white); margin: 0 0 12px; letter-spacing: -0.005em; }
.orion-title em { font-family: var(--o-italic); font-style: italic; color: var(--o-gold-2); }
.orion-lede { font-family: var(--o-body); font-size: 14px; line-height: 1.65; color: var(--o-white-2); margin: 0 0 18px; max-width: 620px; }
.orion-lede strong { color: var(--o-white); font-weight: 600; }
.orion-trust { display: flex; flex-wrap: wrap; gap: 10px 22px; padding: 14px 0; border-top: 1px solid var(--o-line); border-bottom: 1px solid var(--o-line); margin-bottom: 18px; }
.orion-trust span { display: inline-flex; align-items: center; gap: 8px; font-family: var(--o-mono); font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--o-muted); }
.orion-trust span::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--o-sage); }
.orion-disclaimer { margin-top: 4px; }
.orion-disclaimer .h { font-family: var(--o-mono); font-size: 8.5px; letter-spacing: 0.22em; text-transform: uppercase; margin-bottom: 6px; padding-top: 11px; border-top: 1px solid var(--o-amber); color: var(--o-amber); }
.orion-disclaimer .h.brass { border-top-color: var(--o-gold-2); color: var(--o-gold-2); }
.orion-disclaimer p { font-family: var(--o-body); font-size: 10px; line-height: 1.6; color: var(--o-muted); margin: 0 0 12px; }
