/* ===== WINDOWS 98 BASE STYLES & RESET ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-family: var(--font-family);
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-normal);
    line-height: var(--line-height-normal);
    color: var(--text-primary);
    background: var(--bg-primary);
    min-height: 100vh;
    padding: var(--spacing-md);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
}

h1 { font-size: var(--font-size-3xl); }
h2 { font-size: var(--font-size-2xl); }
h3 { font-size: var(--font-size-xl); }
h4 { font-size: var(--font-size-lg); }
h5 { font-size: var(--font-size-base); }
h6 { font-size: var(--font-size-sm); }

p {
    margin-bottom: var(--spacing-md);
    color: var(--text-secondary);
}

a {
    color: var(--text-accent);
    text-decoration: underline;
}

a:focus {
    color: var(--primary-color);
}

/* Focus styles for accessibility */
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 1px dotted var(--win98-black);
    outline-offset: -1px;
}

/* Windows 98 Button Base Style */
button {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    color: var(--text-primary);
    background: var(--button-face);
    border: 1px outset var(--button-face);
    padding: var(--spacing-sm) var(--spacing-md);
    cursor: pointer;
    min-width: 75px;
    height: 23px;
    box-sizing: border-box;
}

button:active {
    border: 1px inset var(--button-face);
}

button:disabled {
    color: var(--text-muted);
    cursor: default;
}

/* Windows 98 Input Base Style */
input, select, textarea {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    color: var(--text-primary);
    background: var(--bg-accent);
    border: 1px inset var(--button-face);
    padding: var(--spacing-xs) var(--spacing-sm);
    height: 21px;
    box-sizing: border-box;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type="number"] {
    -moz-appearance: textfield;
}

/* List styles */
ul, ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

ul li {
    margin-bottom: var(--spacing-xs);
}

/* Image styles */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Selection styles */
::selection {
    background: var(--win98-dark-blue);
    color: var(--win98-white);
}

::-moz-selection {
    background: var(--win98-dark-blue);
    color: var(--win98-white);
}

/* Classic Windows 98 Scrollbar */
::-webkit-scrollbar {
    width: 16px;
    height: 16px;
}

::-webkit-scrollbar-track {
    background: var(--win98-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--win98-gray);
    border: 1px outset var(--win98-gray);
}


::-webkit-scrollbar-corner {
    background: var(--win98-gray);
}

/* Windows 98 Window Frame */
.window {
    background: var(--window-bg);
    border: 2px outset var(--window-bg);
    margin: var(--spacing-md);
}

.window-title {
    background: var(--primary-color);
    color: var(--win98-white);
    padding: var(--spacing-xs) var(--spacing-sm);
    font-weight: var(--font-weight-bold);
    font-size: var(--font-size-sm);
    margin: -2px -2px var(--spacing-md) -2px;
}

.window-content {
    padding: var(--spacing-md);
}

/* Disable modern effects */
* {
    box-shadow: none !important;
    text-shadow: none !important;
    border-radius: 0 !important;
    background-image: none !important;
    transition: none !important;
    animation: none !important;
    transform: none !important;
}

/* Re-enable specific Windows 98 borders */
button, input, select, textarea, .window {
    box-shadow: none !important;
}