@import url("./study.css");

:root {
    color-scheme: light;
    /* ZDrSEM logo and the blue, cyan and green used on zdrsem.cz. */
    --turquoise: #079bb0;
    --blue: #005c93;
    --blue-light: #e1f2f6;
    --navy: #0f274e;
    --green: #59b200;
    --button-green: #3e7d00;
    --button-green-hover: #326600;
    --ink: #191919;
    --muted: #204a62;
    --line: #c8e8ee;
    --paper: #fff;
    --ground: #eff8fa;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, Arial, sans-serif;
    color: var(--ink);
    background: var(--ground);
    line-height: 1.55;
    -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--ground); color: var(--ink); }
.shell { width: min(1100px, calc(100% - 2.5rem)); margin-inline: auto; }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .4rem; }
.brand { display: block; width: 12rem; height: auto; max-width: 50%; }

h1, h2, p { margin: 0; overflow-wrap: anywhere; }
h1, h2 { color: var(--blue); text-wrap: balance; line-height: 1.18; letter-spacing: -.035em; }
h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: 1.4rem; }
h1:focus { outline: none; }
p { color: var(--muted); }
.eyebrow { font-size: .79rem; color: var(--blue); text-transform: uppercase; letter-spacing: .12em; font-weight: 750; margin-bottom: .55rem; }
a, button.link { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; }
a:hover, button.link:hover { color: var(--navy); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
button.primary, a.primary, button.secondary, button.link, .fields input {
    font: inherit;
    border-radius: 5px;
    min-height: 3rem;
    padding: .7rem 1.1rem;
    border: 1px solid transparent;
}
button.primary, button.secondary, button.link { font-weight: 650; cursor: pointer; }
button.primary, a.primary {
    background: var(--button-green);
    color: var(--paper);
    margin-top: .8rem;
    text-transform: uppercase;
    font-weight: 750;
    letter-spacing: .025em;
}
a.primary { display: inline-block; text-decoration: none; }
button.primary::after, a.primary::after {
    content: "";
    display: inline-block;
    width: .45em;
    height: .45em;
    margin-left: .7em;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: translateY(-.06em) rotate(45deg);
}
button.primary:hover, a.primary:hover { background: var(--button-green-hover); }
button.secondary { background: var(--blue-light); border-color: var(--line); color: var(--blue); }
button.secondary:hover { background: #d7edf2; }
button.link { padding-inline: 0; background: transparent; margin-top: .7rem; }
button:disabled { opacity: .65; cursor: wait; }

.login-panel, .courses article, .notice {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: .875rem;
    box-shadow: 0 .6rem 2rem #005c930b;
}
.login-panel {
    display: grid;
    grid-template-columns: .95fr 1.05fr;
    max-width: 940px;
    margin: clamp(2rem, 9vh, 6rem) auto;
    overflow: hidden;
}
.login-art { display: grid; place-items: center; background: var(--blue); padding: 1rem; }
.login-art img { width: 100%; height: auto; }
.login-body { padding: clamp(2rem, 5vw, 4rem); align-self: center; min-width: 0; }
.login-body h1 { font-size: clamp(1.8rem, 3.1vw, 2.4rem); margin-bottom: 1rem; }
.login-body .address { color: var(--ink); margin-top: .35rem; }
.address a { display: inline-flex; align-items: center; min-height: 44px; margin-right: .5rem; }
.fields { display: grid; gap: .5rem; margin-top: 1.25rem; }
.fields label { font-weight: 650; }
.fields input { background: var(--paper); border-color: #7396ab; width: 100%; min-width: 0; color: var(--ink); }
.fields .code { font-size: 1.3rem; letter-spacing: .2em; font-variant-numeric: tabular-nums; }
.error { color: #a52622; }
.subtle { display: inline-flex; align-items: center; min-height: 44px; margin-top: 1rem; font-weight: 600; }

.course-page { padding: clamp(2rem, 7vw, 4.5rem) 0; }
.course-page h1 { margin-bottom: clamp(1.6rem, 3.5vw, 2.5rem); }
.courses { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.45rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); }
.courses article { height: 100%; padding: 1.8rem; }
.course-icon { color: var(--turquoise); display: block; margin-bottom: 1.6rem; }
.courses li:nth-child(even) .course-icon { color: var(--blue); }
.courses p { margin-top: .75rem; }
.notice { padding: 1.7rem; }
.notice button { margin-top: 1rem; }
#blazor-error-ui { display: none; position: fixed; inset: auto 0 0; z-index: 100; padding: 1rem; background: #fff1cb; color: #582f15; }

@media (max-width: 730px) {
    .topbar { min-height: 4.5rem; gap: .6rem; }
    .brand { width: 9.25rem; }
    button.secondary { padding-inline: .85rem; }
    .login-panel { max-width: 470px; grid-template-columns: minmax(0, 1fr); margin-block: 1.4rem; }
    .login-art { padding: .5rem; }
    .login-art img { width: auto; max-width: 100%; height: clamp(88px, 16vh, 140px); }
    .login-body { padding: 1.5rem 1.25rem 1rem; }
    .courses { gap: 1rem; }
    .courses article { padding: 1.4rem; }
    .course-icon { margin-bottom: 1rem; }
}

@media (max-height: 620px) and (max-width: 730px) {
    .login-art { display: none; }
}
