/* hudym.com: the look of the original site (www.hudym.com), its rules that the page uses */

/* The theme: the system's (automatic) until a visitor picks one by the button at the top
   (public/js/theme.js sets data-theme on <html>) */
:root {
    color-scheme: light dark;
    --text: light-dark(#666, #9a9a9a);
    --background: light-dark(#ebebeb, #17191c);
    --accent: light-dark(#0084ff, #4da3ff);
    --line: light-dark(#d2d2d2, #33363b);
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }

* { margin: 0; padding: 0; }

html, body {
    height: 100%;
    font: 14px Tahoma, "Lucida Grande CE", lucida, sans-serif;
    color: var(--text);
    background: var(--background);
    text-align: center;
}

img { vertical-align: middle; border: none; }

a:link, a:visited, a:active, a:hover { color: var(--accent); text-decoration: none; }

h1 { color: var(--accent); font-size: 35px; font-weight: bold; margin-bottom: 30px; }

.main { margin: 150px auto; width: 300px; text-align: center; }
.main > img { margin: 0 0 55px; height: auto; max-width: 100%; }
.main > address,
.main > p { margin: 0 0 15px; line-height: 140%; text-align: left; font-style: normal; }

/* The logo's dark-background version (its lettering light) */
.logo-dark { display: none; }
:root[data-theme="dark"] .logo-light { display: none; }
:root[data-theme="dark"] .logo-dark { display: inline; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .logo-light { display: none; }
    :root:not([data-theme="light"]) .logo-dark { display: inline; }
}

/* The theme's button at the top: automatic → the other one than the system's → the system's → automatic */
.theme-toggle {
    position: fixed;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: transparent;
    color: var(--text);
    cursor: pointer;
}
.theme-toggle[hidden] { display: none; }
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
.theme-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-toggle svg { display: none; width: 20px; height: 20px; }
.theme-toggle[data-mode="auto"] .theme-auto,
.theme-toggle[data-mode="light"] .theme-light,
.theme-toggle[data-mode="dark"] .theme-dark { display: block; }
