/* Pluto Capital style guide v1.0 (29 Nov 2026) applied to the Django admin.
   Colours: navy #102235, antique gold #C7A46A, warm ivory #F3EBDD, text bronze #806136,
   body ink #253345, slate #66707A, canvas #F7F5F0, divider #D9D5CC, paper #FFFFFF.
   Gold is for rules and accents only: it fails contrast as text on light backgrounds. */
:root, html[data-theme="light"], html[data-theme="dark"] {
  --pc-navy: #102235; --pc-gold: #C7A46A; --pc-ivory: #F3EBDD; --pc-bronze: #806136;
  --pc-ink: #253345; --pc-slate: #66707A; --pc-canvas: #F7F5F0; --pc-divider: #D9D5CC;

  --primary: var(--pc-navy);
  --secondary: var(--pc-navy);
  --accent: var(--pc-gold);
  --primary-fg: #fff;
  --body-fg: var(--pc-ink);
  --body-bg: #fff;
  --body-quiet-color: var(--pc-slate);
  --body-medium-color: var(--pc-ink);
  --body-loud-color: var(--pc-navy);
  --header-color: var(--pc-ink);
  --header-branding-color: var(--pc-navy);
  --header-bg: #fff;
  --header-link-color: var(--pc-navy);
  --breadcrumbs-fg: var(--pc-slate);
  --breadcrumbs-link-fg: var(--pc-navy);
  --breadcrumbs-bg: var(--pc-canvas);
  --link-fg: var(--pc-navy);
  --link-hover-color: var(--pc-bronze);
  --link-selected-fg: var(--pc-bronze);
  --hairline-color: var(--pc-divider);
  --border-color: var(--pc-divider);
  --darkened-bg: var(--pc-canvas);
  --selected-bg: var(--pc-ivory);
  --selected-row: #FBF6EC;
  --button-fg: #fff;
  --button-bg: var(--pc-navy);
  --button-hover-bg: #1d3550;
  --default-button-bg: var(--pc-navy);
  --default-button-hover-bg: #1d3550;
  --close-button-bg: var(--pc-slate);
  --close-button-hover-bg: var(--pc-ink);
  --object-tools-fg: #fff;
  --object-tools-bg: var(--pc-navy);
  --object-tools-hover-bg: #1d3550;
  --message-success-bg: #E7F0EA;
  --message-warning-bg: #FBF0DC;
  --message-error-bg: #F8E6E6;
  --error-fg: #9B1C1C;
  --font-family-primary: Arial, "Liberation Sans", "Helvetica Neue", Helvetica, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { color-scheme: light; }
}

body { font-size: 1rem; line-height: 1.5; color: var(--pc-ink); }
h1, h2, #site-name, .module caption, .module h2, #content h1 {
  font-family: Georgia, "DejaVu Serif", "Times New Roman", serif;
}
#content h1 { color: var(--pc-navy); font-weight: 400; font-size: 2rem; }

/* Header: white bar with the horizontal companion logo and a fine gold rule. */
#header { border-bottom: 2px solid var(--pc-gold); padding: 8px 40px; }
#site-name a { display: inline-block; line-height: 0; }
#site-name img { width: 300px; height: auto; max-width: 70vw; }
#user-tools { color: var(--pc-ink); }
#user-tools a, #logout-form button { color: var(--pc-navy); border-bottom-color: var(--pc-divider); }
.theme-toggle { display: none; } /* one light theme, as the style guide defines */

/* Section headers: navy with white text, Georgia. */
.module h2, .module caption, .inline-group h2 {
  background: var(--pc-navy); color: #fff; font-weight: 400; letter-spacing: 0;
}
.module h2 a, .module caption a, .module caption a.section, #nav-sidebar .module caption a,
.app-list .current-app .section:link, .app-list .current-app .section:visited { color: #fff; }
#nav-sidebar .current-app .section { text-decoration: underline; text-decoration-color: var(--pc-gold); text-underline-offset: 4px; }

/* Tables: navy-on-canvas column headers, light alternate rows, thin dividers. */
thead th, tfoot td { background: var(--pc-canvas); color: var(--pc-navy); border-color: var(--pc-divider); }
#changelist table tbody tr:nth-child(even) { background: #FBFAF7; }
td, th { border-bottom-color: var(--pc-divider); }

/* Controls: at least 44 px high, 6 px radius, 3 px navy focus ring. */
.button, input[type=submit], input[type=button], .submit-row input, a.button,
.object-tools a { border-radius: 6px; min-height: 44px; }
.button, input[type=submit], input[type=button], .submit-row input, a.button { padding: 10px 18px; }
.object-tools a { display: inline-flex; align-items: center; }
input[type=text], input[type=password], input[type=email], input[type=number],
input[type=date], select, textarea { border-radius: 6px; border-color: var(--pc-divider); }
:focus-visible { outline: 3px solid var(--pc-navy); outline-offset: 2px; }
.module, #changelist-filter, .login #container { border-radius: 8px; }

/* Login page: show the full horizontal logo centred. */
.login #header { justify-content: center; padding: 20px; }
.login #site-name img { width: 300px; }

/* Admin's own rules for the current app and object tools are more specific; win them here. */
#nav-sidebar .current-app .section:link, #nav-sidebar .current-app .section:visited,
#content-main .current-app .section:link, #content-main .current-app .section:visited { color: #fff !important; }
#nav-sidebar .current-model { background: var(--pc-ivory); }
.object-tools a:link, .object-tools a:visited { display: inline-flex !important; align-items: center; }
