/* Base Styles */
body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    margin: 20px;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: background-color 0.3s, color 0.3s;
    line-height: 1.6;
}

h1, h2 {
    color: var(--heading-color);
    text-align: center;
    margin-bottom: 20px;
}

form, table, .card {
    background: var(--card-bg);
    padding: 20px;
    margin: 20px auto;
    max-width: 800px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

input[type="submit"], button, select, a.button-link {
    padding: 10px 18px;
    font-size: 16px;
    margin-top: 10px;
    border-radius: 6px;
    background-color: #0066cc;
    color: white;
    border: none;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: background-color 0.2s;
}

input[type="submit"]:hover,
button:hover,
a.button-link:hover {
    background-color: #004a99;
}

table {
    border-collapse: collapse;
    width: 100%;
    margin-top: 20px;
}

table, th, td {
    border: 1px solid #ccc;
    padding: 10px;
    text-align: left;
}

tr:hover {
    background-color: var(--row-hover);
}

ul {
    list-style-type: none;
    padding-left: 0;
}

li {
    margin: 10px 0;
}

a {
    color: var(--link-color);
    font-weight: 600;
}

a:hover {
    text-decoration: underline;
}

/* Light Theme */
:root {
    --bg-color: #f5f7fa;
    --text-color: #222;
    --heading-color: #333;
    --link-color: #0056b3;
    --card-bg: #fff;
    --row-hover: #eef;
}

/* Dark Theme */
body.dark-mode {
    --bg-color: #121212;
    --text-color: #e0e0e0;
    --heading-color: #ffffff;
    --link-color: #66ccff;
    --card-bg: #1e1e1e;
    --row-hover: #222;
}

@media (max-width: 600px) {
    body {
        font-size: 16px;
        margin: 10px;
    }

    form, table {
        padding: 15px;
        font-size: 16px;
    }

    table {
        overflow-x: auto;
        display: block;
        white-space: nowrap;
    }

    input[type="number"],
    input[type="text"],
    select {
        width: 100%;
    }
}