/*
 * Uni Hub Tickets — pretix backend skin.
 *
 * Served two ways by pretix_unihub_theme.signals: inline in a <style nonce> so it applies at
 * parse time, and as a <link> fallback. Both carry this same file, so it must contain no
 * url() that resolves relative to the sheet — the brand mark below is a data URI for that
 * reason.
 *
 * The :root blocks are machine-written. Run `python tools/generate_theme.py` after upgrading
 * pretix; tests/test_generated.py fails if they drift.
 */

/* >>> generated: pretix theme variables — tools/generate_theme.py */
:root {
  --pretix-brand-primary: #1155D4;
  --pretix-link-contrast-color: #1155D4;
  --pretix-link-hover-contrast-color: #0b398d;
  --pretix-brand-primary-lighten-5: #135eec;
  --pretix-brand-primary-lighten-20: #598ef2;
  --pretix-brand-primary-lighten-30: #89aff5;
  --pretix-brand-primary-lighten-40: #b8cff9;
  --pretix-brand-primary-lighten-48: #dde8fc;
  --pretix-brand-primary-lighten-50: #e7effd;
  --pretix-brand-primary-lighten-53: #f5f8fe;
  --pretix-brand-primary-darken-5: #0f4cbc;
  --pretix-brand-primary-darken-10: #0d42a5;
  --pretix-brand-primary-darken-15: #0b398d;
  --pretix-brand-primary-darken-17: #0b3584;
  --pretix-brand-primary-darken-20: #092f76;
  --pretix-brand-primary-darken-30: #061c46;
  --pretix-brand-primary-tint-90: #e7eefb;
  --pretix-brand-primary-shade-25: #0d409f;
  --pretix-brand-primary-shade-42: #0a317b;
  --pretix-brand-primary-lighten-28-saturate-20: #75a5ff;
  --pretix-brand-primary-lighten-23-saturate-2: #6698f4;
  --pretix-body-bg: #F6F6F8;
  --pretix-body-bg-white-1: 0;
  --pretix-body-bg-white-0: 1;
}
/* <<< generated: pretix theme variables */

/* >>> generated: brand mark — tools/generate_theme.py */
:root {
  --unihub-navbar-icon: url("data:image/svg+xml,%3Csvg%20xmlns=%22http://www.w3.org/2000/svg%22%20width=%221024%22%20height=%221024%22%20viewBox=%220%200%201024%201024%22%20role=%22img%22%20aria-label=%22Uni%20Hub%22%3E%20%3Cg%20transform=%22translate(0.000000,1024.000000)%20scale(0.100000,-0.100000)%22%20fill=%22%23fff%22%20stroke=%22none%22%3E%20%3Cpath%20d=%22M5035%209394%20c-333%20-24%20-626%20-117%20-873%20-277%20-51%20-33%20-903%20-631%20-1242%20-872%20-61%20-44%20-1034%20-729%20-1820%20-1283%20-354%20-250%20-677%20-479%20-716%20-508%20-400%20-301%20-468%20-876%20-151%20-1269%2073%20-90%20113%20-123%20417%20-337%20234%20-164%20430%20-303%20725%20-512%20113%20-80%20189%20-140%20187%20-148%20-2%20-7%20-20%20-62%20-39%20-123%20-19%20-60%20-52%20-164%20-73%20-230%20-21%20-66%20-68%20-214%20-104%20-330%20-37%20-115%20-94%20-295%20-127%20-400%20-33%20-104%20-64%20-201%20-69%20-215%20-5%20-14%20-36%20-113%20-70%20-220%20-145%20-460%20-182%20-577%20-195%20-615%20-8%20-22%20-41%20-128%20-75%20-235%20-34%20-107%20-67%20-213%20-75%20-235%20-20%20-60%20-95%20-301%20-95%20-309%200%20-12%2031%20-5%20226%2054%20562%20171%20543%20166%20558%20149%207%20-8%20121%20-151%20251%20-318%20l239%20-304%2014%2039%20c7%2021%2038%20116%2067%20209%2030%2094%2088%20278%20131%20410%2042%20132%2093%20294%20114%20360%2021%2066%2063%20201%2095%20300%2032%2099%2072%20227%2091%20285%2018%2058%2051%20164%2074%20235%2049%20153%20100%20312%20165%20520%2026%2083%2050%20154%2055%20159%208%208%20133%20-79%201086%20-751%20357%20-251%20435%20-302%20569%20-363%20538%20-249%201218%20-202%201706%20118%2062%2041%20289%20199%20639%20447%20117%2083%202329%201642%202850%202009%20381%20268%20471%20356%20555%20540%20137%20300%20101%20642%20-96%20907%20-72%2097%20-119%20138%20-330%20287%20-87%2061%20-1176%20828%20-1264%20890%20-27%2020%20-86%2061%20-130%2092%20-44%2031%20-273%20193%20-510%20360%20-236%20167%20-463%20326%20-502%20354%20-40%2028%20-326%20229%20-635%20447%20-575%20404%20-627%20439%20-758%20504%20-247%20124%20-604%20197%20-865%20179z%20m263%20-900%20c163%20-33%20243%20-75%20502%20-258%20225%20-158%20200%20-141%20760%20-536%20283%20-200%20538%20-379%20565%20-398%2028%20-20%2079%20-56%20115%20-82%2036%20-25%2094%20-66%20130%20-91%2062%20-44%201041%20-734%201145%20-807%2028%20-20%2089%20-63%20136%20-96%20550%20-387%20669%20-472%20669%20-481%200%20-5%20-22%20-24%20-48%20-42%20-26%20-17%20-78%20-53%20-117%20-80%20-464%20-327%20-879%20-620%20-960%20-678%20-55%20-39%20-129%20-92%20-165%20-117%20-36%20-25%20-319%20-224%20-630%20-443%20-311%20-219%20-623%20-440%20-695%20-490%20-71%20-50%20-344%20-242%20-605%20-427%20-495%20-348%20-558%20-390%20-650%20-426%20-293%20-114%20-604%20-71%20-880%20123%20-841%20592%20-1046%20737%20-1048%20744%20-2%205%20498%20405%201111%20889%20612%20484%201129%20898%201147%20918%2095%20109%20126%20297%2072%20440%20-25%2065%20-526%20716%20-615%20798%20-108%20101%20-266%20134%20-421%2090%20-78%20-22%20-55%20-4%20-1418%20-1082%20-714%20-565%20-1306%20-1028%20-1313%20-1030%20-8%20-2%20-221%20142%20-472%20319%20-252%20177%20-489%20344%20-528%20372%20-38%2027%20-91%2063%20-117%2080%20-26%2018%20-48%2037%20-48%2042%200%206%20109%2087%20242%20180%20133%2094%20264%20186%20292%20206%2028%2020%20344%20242%20701%20494%20358%20252%20673%20474%20700%20493%2028%2020%2086%2061%20130%2092%20100%2070%201140%20804%201370%20966%20288%20204%20308%20217%20380%20250%20176%2081%20381%20106%20563%2068z%22/%3E%20%3C/g%3E%20%3C/svg%3E");
}
/* <<< generated: brand mark */

/* ------------------------------------------------------------------ *
 * Everything below is hand-written: pretix bakes these colours in at
 * SCSS compile time, so no custom property reaches them.
 * tests/test_literals.py fails if pretix adds one this file misses.
 * ------------------------------------------------------------------ */

/* Top bar. Stock is $navbar-inverse-bg #3b1c4a and its shades. */
.navbar-inverse {
    background-color: var(--pretix-brand-primary);
    border-color: var(--pretix-brand-primary-darken-15);
}

.navbar-inverse .navbar-nav > .active > a,
.navbar-inverse .navbar-nav > .active > a:hover,
.navbar-inverse .navbar-nav > .active > a:focus,
.navbar-inverse .navbar-nav > .open > a,
.navbar-inverse .navbar-nav > .open > a:hover,
.navbar-inverse .navbar-nav > .open > a:focus,
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a,
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover,
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus {
    background-color: var(--pretix-brand-primary-darken-10);
}

.navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header {
    border-color: var(--pretix-brand-primary-darken-15);
}

.navbar-inverse .navbar-nav .open .dropdown-menu .divider {
    background-color: var(--pretix-brand-primary-darken-15);
}

.navbar-inverse .navbar-collapse,
.navbar-inverse .navbar-form {
    border-color: var(--pretix-brand-primary-darken-20);
}

/* Stock gives the mobile toggle a #333 border, which goes muddy on blue. */
.navbar-inverse .navbar-toggle {
    border-color: rgba(255, 255, 255, 0.4);
}

.navbar-inverse .navbar-toggle:hover,
.navbar-inverse .navbar-toggle:focus {
    background-color: rgba(0, 0, 0, 0.18);
}

/* The mark. Its <img src> is in core's template, so CSS is the only way in. */
.navbar-brand img {
    content: var(--unihub-navbar-icon);
}

/* Sidebar icons — the same $navbar-inverse-bg literal, twice more. */
.sidebar-nav li > a > .fa {
    color: var(--pretix-brand-primary);
}

.sidebar-nav li > a > svg path {
    fill: var(--pretix-brand-primary);
}

/* Event widget's orders button — and again. */
.widget-container.widget-container-event .bottomrow a.orders {
    background: var(--pretix-brand-primary);
}

/* Stock tints every raised surface with a purple shadow, rgba(78, 50, 92, .1). */
dialog.modal-card,
.modal-wrapper .modal-card,
.qr-code-overlay,
.form-signin,
.impersonate-warning {
    box-shadow: 0 7px 14px 0 rgba(15, 23, 42, 0.1), 0 3px 6px 0 rgba(0, 0, 0, 0.07);
}

/* Surfaces. sb-admin-2 paints the body #f8f8f8 and the content slab white, which leaves
   panels invisible against the page; Classic is white cards on #F6F6F8. The auth page sets
   its own #fbf7fc, which the first rule also answers. */
body {
    background-color: var(--pretix-body-bg);
    color: #0f172a;
}

#page-wrapper {
    background-color: var(--pretix-body-bg);
}

@media (min-width: 768px) {
    #page-wrapper {
        border-left-color: #e2e8f0;
    }
}

.navbar-default.sidebar {
    background-color: #ffffff;
    border-color: #e2e8f0;
}

.sidebar ul li,
.sidebar .context-selector {
    border-bottom-color: #e2e8f0;
}

.panel-default {
    border-color: #e2e8f0;
}

.panel-default > .panel-heading,
.panel-default > legend > .panel-heading {
    background-color: #ffffff;
    border-color: #e2e8f0;
}

.dashboard .widget-container {
    background: #ffffff;
    border-color: var(--pretix-body-bg);
}

.dashboard .widget-container:hover,
.dashboard .widget-container:focus {
    background: var(--pretix-brand-primary-tint-90);
}

.table > thead > tr > th,
.table > thead > tr > td,
.table > tbody > tr > th,
.table > tbody > tr > td,
.table > tfoot > tr > th,
.table > tfoot > tr > td {
    border-top-color: #e2e8f0;
}

.table > thead > tr > th {
    border-bottom-color: #e2e8f0;
}

.table-bordered th,
.table-bordered td {
    border-color: #e2e8f0 !important;
}

/* Text. Stock's #737373 muted is 4.39:1 on the Classic page background, under AA; #5C6D83
   is 4.90:1. Input borders are deliberately NOT moved — #949494 is 3.03:1 against white,
   and every Classic outline is far below the 3:1 a control border owes. */
.text-muted,
caption,
.link-muted a,
a.link-muted {
    color: #5c6d83;
}

.text-muted path {
    fill: #5c6d83;
}

.thumbnail .caption,
.product-row-giftcard code {
    color: #0f172a;
}

/* The active sidebar item. Stock fills it #eeeeee — the identical fill :hover uses — so the
   section you are in cannot be told from the one under the cursor. The tint and the weight
   carry the state; the gold is reinforcement, never the only signal. */
#side-menu li a.active {
    background-color: var(--pretix-brand-primary-tint-90);
    box-shadow: inset 3px 0 0 #c99700;
    font-weight: 600;
}

.rtl #side-menu li a.active {
    box-shadow: inset -3px 0 0 #c99700;
}
