﻿/*
 * Custom stylesheet for the Swagger UI (Swashbuckle 5.6 / swagger-ui 2.x).
 * Embedded resource, injected via c.InjectStylesheet(...) in App_Start/WebApiConfig.cs.
 * Changes to THIS file require a rebuild; switching the palette (theme-palette.css) does not.
 *
 * The palette is loaded with an absolute URL because this file is served from
 * /swagger/ui/ext/... and a relative URL would not resolve.
 * The HTTP method colours (GET/POST/PUT/DELETE/PATCH) are intentionally kept - they carry meaning.
 */
@import url("/theme-palette.css");

.swagger-section .swagger-ui-wrap
{
    max-width: 1500px;
}

/* Header bar */
.swagger-section #header {
    background-color: var(--ta-primary);
    border-bottom: 3px solid var(--ta-accent);
}

.swagger-section #header #logo,
.swagger-section #header a#logo {
    color: var(--ta-on-primary);
}

/* Header buttons: Explore / Authorize */
.swagger-section #explore,
.swagger-section #auth_container .authorize__btn {
    color: var(--ta-on-accent);
    background-color: var(--ta-accent);
}

.swagger-section #explore:hover,
.swagger-section #explore:focus,
.swagger-section #auth_container .authorize__btn:hover,
.swagger-section #auth_container .authorize__btn:focus {
    color: var(--ta-on-accent);
    background-color: var(--ta-accent-hover);
}

/* Text and links */
.swagger-section .swagger-ui-wrap {
    color: var(--ta-text);
}

.swagger-section .swagger-ui-wrap a,
.swagger-section .swagger-ui-wrap p#colophon a,
.swagger-section .swagger-ui-wrap .markdown h3,
.swagger-section .auth_container .auth__title {
    color: var(--ta-primary);
}

/* Resource (controller) headings */
.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2,
.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a {
    color: var(--ta-primary);
}

.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a:hover {
    color: var(--ta-primary-dark);
}

.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a {
    color: var(--ta-primary);
}

/* Model / Example Value tabs */
.swagger-section .swagger-ui-wrap .model-signature .signature-nav a {
    color: var(--ta-primary);
}

.swagger-section .swagger-ui-wrap .model-signature .signature-nav a:hover {
    color: var(--ta-primary-dark);
}

.swagger-section .swagger-ui-wrap .model-signature .signature-nav .selected {
    color: var(--ta-text);
    border-bottom: 2px solid var(--ta-accent);
}

/* Parameter / response table headers */
.swagger-section .swagger-ui-wrap table thead tr th {
    color: var(--ta-text);
    border-bottom-color: var(--ta-primary-border);
}

/* "Try it out!" button */
.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header input.submit {
    color: var(--ta-on-accent);
    background-color: var(--ta-accent);
    border: 1px solid var(--ta-accent);
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
}

.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header input.submit:hover,
.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header input.submit:focus {
    background-color: var(--ta-accent-hover);
}
