/* * "retro" theme flourishes — modelled on danlegt.com. * * Windows 98 chrome over a black pixel-star desktop, PixeloidSans pixel font, * crisp (non-antialiased, pixelated) rendering. Scoped entirely to * :root[data-theme="retro"] so it never touches the other themes. * * CSP-safe: external stylesheet + self-hosted fonts only (font-src 'self'), * no inline styles, no remote assets. The starfield is pure CSS so we don't * depend on img-src for a background gif. */ /* Self-hosted pixel fonts (mirrored locally — GGBotNet PixeloidSans is free, PixelOperator is CC0). ------------------------------------------------- */ @font-face { font-family: "PixeloidSans"; src: url("/static/fonts/pixeloid_sans/PixeloidSans.ttf") format("truetype"); font-weight: normal; font-display: swap; } @font-face { font-family: "PixeloidSans"; src: url("/static/fonts/pixeloid_sans/PixeloidSans-Bold.ttf") format("truetype"); font-weight: bold; font-display: swap; } @font-face { font-family: "PixelOperatorMono"; src: url("/static/fonts/pixel_operator/PixelOperatorMono.ttf") format("truetype"); font-weight: normal; font-display: swap; } @font-face { font-family: "PixelOperatorMono"; src: url("/static/fonts/pixel_operator/PixelOperatorMono-Bold.ttf") format("truetype"); font-weight: bold; font-display: swap; } /* Crisp, pixelated, non-smoothed rendering like the source site. */ :root[data-theme="retro"] { font-smooth: never; -webkit-font-smoothing: none; -moz-osx-font-smoothing: unset; } :root[data-theme="retro"] img, :root[data-theme="retro"] .thumb-link img, :root[data-theme="retro"] .preview-stage img { image-rendering: pixelated; } /* Square everything — Win98 had no rounded corners. */ :root[data-theme="retro"] *, :root[data-theme="retro"] *::before, :root[data-theme="retro"] *::after { border-radius: 0 !important; } /* Black desktop with the tiled starfield mirrored from danlegt.com. */ :root[data-theme="retro"] body { background-color: #000000; background-image: url("/static/backgrounds/stars1.gif"); background-repeat: repeat; background-attachment: fixed; image-rendering: pixelated; } /* Selection + focus use the classic dotted/navy treatment. */ :root[data-theme="retro"] ::selection { background: #000078; color: #ffffff; } :root[data-theme="retro"] :focus-visible { outline: 1px dotted #000000; outline-offset: -4px; } /* Header: thin flat silver toolbar with a bottom bevel. */ :root[data-theme="retro"] .site-header { background: #c0c0c0; backdrop-filter: none; -webkit-backdrop-filter: none; border-bottom: 2px solid #404040; box-shadow: inset 0 1px 0 #ffffff; } :root[data-theme="retro"] .nav { min-height: 2.1rem; } :root[data-theme="retro"] .site-header .button { min-height: 1.6rem; padding: 0.15rem 0.6rem; } :root[data-theme="retro"] .brand { color: #000000; font-size: 0.95rem; } :root[data-theme="retro"] .brand-mark { width: 1.4rem; height: 1.4rem; background: linear-gradient(90deg, #000078, 80%, #0f80cd); color: #ffffff; font-size: 0.75rem; box-shadow: inset -1px -1px 0 #404040, inset 1px 1px 0 #6f6fff; } /* Cards are raised silver windows with black text. */ :root[data-theme="retro"] .card { background: linear-gradient(to bottom, #ffffff, 4%, #c0c0c0 8%); background-color: #c0c0c0; color: #000000; border: 1px solid #000000; box-shadow: var(--shadow); backdrop-filter: none; -webkit-backdrop-filter: none; } /* Headings become Win98 active title bars. */ :root[data-theme="retro"] h1 { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin: -0.35rem -0.35rem 1rem; padding: 0.35rem 0.5rem; background: linear-gradient(to right, #000078, 80%, #0f80cd); color: #ffffff; font-size: 1rem; font-weight: 700; letter-spacing: 0; text-shadow: none; } /* Fake window control button on the right of every title bar. */ :root[data-theme="retro"] h1::after { content: "✕"; display: grid; place-items: center; width: 1.15rem; height: 1rem; background: #c0c0c0; color: #000000; font-size: 0.7rem; font-weight: 700; box-shadow: inset -1px -1px 0 #404040, inset 1px 1px 0 #ffffff, inset -2px -2px 0 #808080, inset 2px 2px 0 #dfdfdf; } /* Links: classic blue, underlined, purple when visited. */ :root[data-theme="retro"] a:not(.button):not(.brand) { color: #0000ee; text-decoration: underline; } :root[data-theme="retro"] a:not(.button):not(.brand):visited { color: #551a8b; } :root[data-theme="retro"] a:not(.button):not(.brand):hover { color: #ee0000; } /* Buttons: grey beveled chunks that press in when active. */ :root[data-theme="retro"] .button, :root[data-theme="retro"] button { background: #c0c0c0; color: #000000; border: 1px solid #000000; font-weight: 700; box-shadow: inset -1px -1px 0 #404040, inset 1px 1px 0 #ffffff, inset -2px -2px 0 #808080, inset 2px 2px 0 #dfdfdf; } :root[data-theme="retro"] .button:hover, :root[data-theme="retro"] button:hover { background: #d4d0c8; } :root[data-theme="retro"] .button:active, :root[data-theme="retro"] button:active, :root[data-theme="retro"] .button.is-active { background: #c0c0c0; box-shadow: inset 1px 1px 0 #404040, inset -1px -1px 0 #ffffff, inset 2px 2px 0 #808080, inset -2px -2px 0 #dfdfdf; padding-top: calc(0.45rem + 1px); padding-left: calc(0.85rem + 1px); } /* The primary call-to-action gets the blue title-bar gradient. */ :root[data-theme="retro"] .button-primary { background: linear-gradient(to right, #000078, 80%, #0f80cd); color: #ffffff; } :root[data-theme="retro"] .button-primary:hover { background: linear-gradient(to right, #0a0a9a, 80%, #1a90dd); } :root[data-theme="retro"] .button-danger { background: #c0c0c0; color: #c00000; border-color: #000000; } /* Inputs and selects look sunken (inset bevel). */ :root[data-theme="retro"] input, :root[data-theme="retro"] select, :root[data-theme="retro"] textarea { background: #ffffff; color: #000000; border: 1px solid #000000; box-shadow: inset 1px 1px 0 #808080, inset -1px -1px 0 #ffffff; } :root[data-theme="retro"] input:focus, :root[data-theme="retro"] select:focus { outline: 1px dotted #000000; outline-offset: -3px; } /* Labels inside windows read black, not muted-grey-on-grey. */ :root[data-theme="retro"] label span, :root[data-theme="retro"] .stack-form label, :root[data-theme="retro"] .form-footer p, :root[data-theme="retro"] .drop-copy, :root[data-theme="retro"] .drop-meta, :root[data-theme="retro"] .upload-subtitle, :root[data-theme="retro"] .download-subtitle, :root[data-theme="retro"] .muted-copy, :root[data-theme="retro"] .kicker, :root[data-theme="retro"] .checkbox-field span { color: #1a1a1a; } /* API / docs page: the header is a real full-width window with the intro text inside it, and each section card gets a Win98 title bar from its