/* =========================================================
   BRAND BOOK — MASTER STYLESHEET
   A Cattle Management System
   ========================================================= */

/* =========================================================
   1. THEME TOKENS
   Dark mode is applied to <html class="dark-mode">
   ========================================================= */

:root {
    color-scheme: light;

    --bg-color: #eef2ed;
    --text-color: #1e2a22;
    --muted-text: #667269;

    --container-bg: #ffffff;
    --card-bg: #ffffff;
    --soft-bg: #f5f8f5;
    --raised-bg: #ffffff;

    --border-color: #d8e0d9;
    --border-strong: #c4d0c6;

    --highlight-color: #245f38;
    --highlight-hover: #18472a;
    --highlight-soft: #e5f0e8;

    --success-color: #2f7d46;
    --success-hover: #246437;

    --danger-color: #c74444;
    --danger-hover: #a83434;

    --warning-color: #d6a83b;
    --warning-soft: #f8e9bd;

    --info-color: #3f6f9f;

    --white: #ffffff;
    --black: #000000;

    --shadow-sm: 0 3px 10px rgba(26, 50, 33, 0.07);
    --shadow-md: 0 10px 28px rgba(26, 50, 33, 0.11);
    --shadow-lg: 0 18px 42px rgba(26, 50, 33, 0.15);

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;

    --focus-ring: 0 0 0 3px rgba(36, 95, 56, 0.18);
}

:root.dark-mode {
    color-scheme: dark;

    --bg-color: #111612;
    --text-color: #edf3ee;
    --muted-text: #aab7ad;

    --container-bg: #1a211c;
    --card-bg: #1a211c;
    --soft-bg: #222b24;
    --raised-bg: #202822;

    --border-color: #303b32;
    --border-strong: #405044;

    --highlight-color: #4f9a66;
    --highlight-hover: #63ae79;
    --highlight-soft: #213b29;

    --success-color: #4f9a66;
    --success-hover: #63ae79;

    --danger-color: #d95c5c;
    --danger-hover: #eb7373;

    --warning-color: #e1b852;
    --warning-soft: #4c3d17;

    --info-color: #74a7d9;

    --shadow-sm: 0 3px 12px rgba(0, 0, 0, 0.28);
    --shadow-md: 0 12px 32px rgba(0, 0, 0, 0.34);
    --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.42);

    --focus-ring: 0 0 0 3px rgba(79, 154, 102, 0.25);
}


/* =========================================================
   2. RESET & GLOBALS
   ========================================================= */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--bg-color);
}

body {
    min-height: 100vh;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;

    color: var(--text-color);
    background: var(--bg-color);

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    line-height: 1.5;

    transition:
        background-color 0.2s ease,
        color 0.2s ease;
}

img {
    max-width: 100%;
}

a {
    color: var(--highlight-color);
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

h1,
h2,
h3,
h4,
h5,
h6,
p,
label,
span,
th,
td {
    color: inherit;
}

h1 {
    margin: 0 0 20px;
    color: var(--highlight-color);
    font-size: 32px;
    line-height: 1.15;
}

h2 {
    margin: 0 0 15px;
    color: var(--text-color);
}

h3,
h4,
h5,
h6 {
    color: var(--text-color);
}

p {
    color: var(--text-color);
}

.hidden {
    display: none !important;
}


/* =========================================================
   3. GENERAL PAGE LAYOUT
   ========================================================= */

.container {
    width: min(1000px, calc(100% - 30px));
    margin: 50px auto 30px;
    padding: 24px;

    color: var(--text-color);
    background: var(--container-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);

    text-align: center;
}

.logo {
    width: 100px;
    height: auto;
}

.section {
    margin-bottom: 24px;
    padding: 20px;

    color: var(--text-color);
    background: var(--card-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.section:last-child {
    margin-bottom: 0;
}


/* =========================================================
   4. TOP CONTROLS
   ========================================================= */

.theme-toggle {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 20;
}

.theme-toggle button,
.version-button,
.settings-panel > button {
    min-height: 42px;
    padding: 9px 14px;

    color: var(--white);
    background: var(--highlight-color);

    border: none;
    border-radius: var(--radius-sm);

    text-decoration: none;
    font-weight: 700;
    cursor: pointer;

    box-shadow: var(--shadow-sm);

    transition:
        background-color 0.18s ease,
        transform 0.18s ease;
}

.theme-toggle button:hover,
.version-button:hover,
.settings-panel > button:hover {
    background: var(--highlight-hover);
    transform: translateY(-1px);
}

.version-button {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 20;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 10px 18px;

    font-size: 15px;
    text-align: center;
}

.settings-panel {
    margin: 1em;
    text-align: right;
}

#settings {
    margin-top: 7px;
    padding: 12px;

    color: var(--text-color);
    background: var(--raised-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);

    text-align: left;
}

#settings label {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    min-height: 34px;

    color: var(--text-color);
}

#settings input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--highlight-color);
}


/* =========================================================
   5. FORMS
   ========================================================= */

form {
    color: var(--text-color);
}

form input[type="text"],
form input[type="date"],
form input[type="url"],
form input[type="number"],
form input[type="email"],
form input[type="password"],
form input[type="search"],
form input[type="file"],
form textarea,
form select,
.search-bar,
.search-box input,
.filter-dropdown,
#cow-search,
#sire-search {
    width: 100%;
    padding: 10px 12px;

    color: var(--text-color);
    background: var(--card-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);

    font-size: 16px;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        background-color 0.18s ease;
}

form input[type="text"],
form input[type="date"],
form input[type="url"],
form input[type="number"],
form input[type="email"],
form input[type="password"],
form textarea,
form select {
    margin-bottom: 15px;
}

form textarea {
    min-height: 110px;
    resize: vertical;
}

form input:focus,
form textarea:focus,
form select:focus,
.search-bar:focus,
.search-box input:focus,
.filter-dropdown:focus,
#cow-search:focus,
#sire-search:focus {
    outline: none;
    border-color: var(--highlight-color);
    box-shadow: var(--focus-ring);
}

input::placeholder,
textarea::placeholder {
    color: var(--muted-text);
    opacity: 0.85;
}

form button {
    width: 100%;
    padding: 12px;

    color: var(--white);
    background: var(--highlight-color);

    border: none;
    border-radius: var(--radius-sm);

    font-size: 16px;
    font-weight: 700;
    cursor: pointer;

    transition:
        background-color 0.18s ease,
        transform 0.18s ease;
}

form button:hover {
    background: var(--highlight-hover);
}

form button:active {
    transform: translateY(1px);
}


/* =========================================================
   6. GENERAL BUTTONS
   ========================================================= */

.btn,
.action-button,
.dashboard-btn,
.dropdown-btn,
.dropdown-item,
.edit-button,
.delete-button,
.export-btn,
.logout-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 42px;
    padding: 10px 14px;

    border: none;
    border-radius: var(--radius-sm);

    text-align: center;
    text-decoration: none;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;

    transition:
        background-color 0.18s ease,
        color 0.18s ease,
        transform 0.18s ease;
}

.btn,
.edit-button {
    color: var(--white);
    background: var(--highlight-color);
}

.btn:hover,
.edit-button:hover {
    background: var(--highlight-hover);
}

.action-button,
.dashboard-btn,
.dropdown-btn,
.dropdown-item,
.export-btn {
    color: var(--white);
    background: var(--success-color);
}

.action-button:hover,
.dashboard-btn:hover,
.dropdown-btn:hover,
.dropdown-item:hover,
.export-btn:hover {
    color: var(--white);
    background: var(--success-hover);
}

.delete-button,
.delete-btn,
.logout-btn {
    color: var(--white);
    background: var(--danger-color);
}

.delete-button:hover,
.delete-btn:hover,
.logout-btn:hover {
    color: var(--white);
    background: var(--danger-hover);
}

.btn {
    width: 150px;
    margin-bottom: 20px;
}

.logout-btn {
    margin-top: 20px;
    padding: 12px 25px;
}


/* =========================================================
   7. DASHBOARD
   ========================================================= */

.dashboard-section {
    margin-bottom: 24px;
    padding: 20px;

    color: var(--text-color);
    background: var(--card-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.dashboard-section h2 {
    color: var(--text-color);
}

.dashboard-btn-group {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
}

.dashboard-btn {
    width: 160px;
    min-height: 54px;
    padding: 14px;

    color: var(--white);
    background: var(--success-color);

    border-radius: var(--radius-sm);

    font-size: 16px;
}

.dashboard-btn:hover {
    background: var(--success-hover);
}


/* =========================================================
   8. ACTION / FILTER BARS
   ========================================================= */

.calves-actions,
.cows-actions,
.sires-actions,
.journal-actions,
.pasture-actions,
.vaccines-actions,
.top-actions,
.filter-container,
.action-filters {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;

    gap: 10px;
    margin-bottom: 20px;
}

.calves-actions,
.cows-actions,
.sires-actions {
    justify-content: space-between;
}

.action-filters select,
.action-filters input {
    width: auto;
    min-width: 180px;
}

.search-bar {
    display: block;
    max-width: 420px;
    margin: 0 auto 20px;
}

.search-box {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.search-box input {
    width: min(100%, 360px);
}

#cow-search,
#sire-search {
    width: min(100%, 360px);
}

.filter-dropdown {
    width: auto;
    min-width: 150px;
}

.cows-actions a,
.cows-actions form button,
.sires-actions a,
.sires-actions form button,
.journal-actions a,
.journal-actions form button,
.vaccines-actions a,
.vaccines-actions form button {
    width: 100%;
    max-width: 210px;
    margin: 5px 0;
    padding: 10px 12px;

    color: var(--white);
    background: var(--highlight-color);

    border-radius: var(--radius-sm);

    text-decoration: none;
    text-align: center;
    font-size: 15px;
}

.cows-actions a:hover,
.cows-actions form button:hover,
.sires-actions a:hover,
.sires-actions form button:hover,
.journal-actions a:hover,
.journal-actions form button:hover,
.vaccines-actions a:hover,
.vaccines-actions form button:hover {
    background: var(--highlight-hover);
}

.cows-actions form input[type="file"],
.sires-actions form input[type="file"],
.journal-actions form input[type="file"],
.vaccines-actions form input[type="file"] {
    width: 100%;
    max-width: 240px;
    margin: 5px 0;
}


/* =========================================================
   9. RECORD LISTS & CARDS
   ========================================================= */

.calves-list,
.cows-list,
.sires-list,
.journal-list,
.pasture-list,
.vaccines-list {
    display: flex;
    flex-direction: column;
    gap: 16px;

    padding: 0;
    margin: 0;
}

.calf-item,
.cow-item,
.sire-item,
.journal-item,
.pasture-item,
.vaccine-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;

    gap: 16px;
    padding: 16px;

    color: var(--text-color);
    background: var(--card-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.calf-item {
    border-width: 2px;
}

.calf-info,
.cow-info,
.sire-info,
.journal-info,
.pasture-info,
.vaccine-info {
    display: grid;
    gap: 14px;

    flex: 1 1 620px;
    margin-bottom: 10px;
}

.calf-info,
.cow-info {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.sire-info,
.pasture-info,
.vaccine-info {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.journal-info {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.calf-info strong,
.cow-info strong,
.sire-info strong,
.journal-info strong,
.pasture-info strong,
.vaccine-info strong {
    display: block;
    margin-bottom: 3px;

    color: var(--text-color);
    font-size: 17px;
}

.calf-info span,
.cow-info span,
.sire-info span,
.journal-info span,
.pasture-info span,
.vaccine-info span {
    display: block;

    color: var(--text-color);
    font-size: 14px;
    overflow-wrap: anywhere;
}

.calf-actions,
.cow-actions,
.sire-actions,
.vaccine-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;

    gap: 8px;
    min-width: 120px;
}

.calf-actions .action-button,
.cow-actions .action-button,
.sire-actions .action-button,
.vaccine-actions .action-button {
    width: 100%;
    margin: 0;
    padding: 8px 12px;

    color: var(--white);
    background: var(--success-color);

    font-size: 14px;
}

.calf-actions .edit-button,
.cow-actions .edit-button,
.sire-actions .edit-button,
.vaccine-actions .edit-button {
    background: var(--highlight-color);
}

.calf-actions .edit-button:hover,
.cow-actions .edit-button:hover,
.sire-actions .edit-button:hover,
.vaccine-actions .edit-button:hover {
    background: var(--highlight-hover);
}


/* =========================================================
   10. DROPDOWNS
   ========================================================= */

.actions-dropdown {
    position: relative;
    display: inline-block;
    margin-left: auto;
}

.dropdown-btn {
    width: 100%;
    padding: 10px 16px;

    color: var(--white);
    background: var(--success-color);

    border: none;
    border-radius: var(--radius-sm);

    font-size: 15px;
}

.dropdown-content {
    display: none;
    position: absolute;
    z-index: 100;

    top: calc(100% + 5px);
    right: 0;

    min-width: 180px;
    overflow: hidden;

    color: var(--text-color);
    background: var(--raised-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
}

@media (hover: hover) and (pointer: fine) {
    .actions-dropdown:hover .dropdown-content {
        display: block;
    }
}

.dropdown-content.show {
    display: block !important;
}

.dropdown-item,
.dropdown-content a,
.dropdown-content form button,
form button.dropdown-item,
button.dropdown-item {
    width: 100%;
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0;
    padding: 10px 14px;

    color: var(--white);
    background: var(--success-color);

    border: none;
    border-radius: 0;

    text-decoration: none;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
}

.dropdown-content .edit-btn,
.dropdown-content a.edit-btn {
    background: var(--highlight-color);
}

.dropdown-content .delete-btn,
.dropdown-content form button.delete-btn {
    background: var(--danger-color);
}

.dropdown-item:hover,
.dropdown-content a:hover,
.dropdown-content form button:hover,
form button.dropdown-item:hover,
button.dropdown-item:hover {
    background: var(--success-hover);
}

.dropdown-content .edit-btn:hover,
.dropdown-content a.edit-btn:hover {
    background: var(--highlight-hover);
}

.dropdown-content .delete-btn:hover,
.dropdown-content form button.delete-btn:hover {
    background: var(--danger-hover);
}


/* =========================================================
   11. TABLES
   ========================================================= */

.table-wrap {
    width: 100%;
    overflow-x: auto;

    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}

table {
    width: 100%;
    border-collapse: collapse;

    color: var(--text-color);
    background: var(--card-bg);
}

th,
td {
    padding: 10px 12px;

    color: var(--text-color);
    border: 1px solid var(--border-color);

    text-align: left;
    vertical-align: top;
}

th {
    background: var(--soft-bg);
    font-weight: 700;
}

tbody tr:nth-child(even) {
    background: color-mix(in srgb, var(--soft-bg) 65%, transparent);
}


/* =========================================================
   12. FLASH MESSAGES
   ========================================================= */

.flash-message {
    margin: 10px 0;
    padding: 11px 14px;

    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);

    text-align: center;
    font-weight: 600;
}

.flash-message.success {
    color: #155724;
    background: #d4edda;
    border-color: #b8dfc2;
}

.flash-message.error {
    color: #721c24;
    background: #f8d7da;
    border-color: #efb9bf;
}

:root.dark-mode .flash-message.success {
    color: #c8f1d1;
    background: #193f24;
    border-color: #2e6b3e;
}

:root.dark-mode .flash-message.error {
    color: #ffd2d6;
    background: #4a2024;
    border-color: #7c353b;
}


/* =========================================================
   13. MODALS
   ========================================================= */

#historyModal,
.history-modal {
    display: none;
    position: fixed;
    z-index: 2000;

    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    width: min(92vw, 560px);
    max-height: 82vh;
    overflow: auto;

    padding: 20px;

    color: var(--text-color);
    background: var(--raised-bg);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
}

#historyModal *,
.history-modal * {
    color: inherit;
}

#closeModal,
.closeModal,
.history-modal .closeModal {
    margin-top: 12px;
    padding: 10px 14px;

    color: var(--white);
    background: var(--highlight-color);

    border: none;
    border-radius: var(--radius-sm);

    cursor: pointer;
}

#closeModal:hover,
.closeModal:hover,
.history-modal .closeModal:hover {
    background: var(--highlight-hover);
}


/* =========================================================
   14. EMPTY STATES
   ========================================================= */

.no-results,
.empty-message {
    padding: 24px;

    color: var(--muted-text);
    text-align: center;
    font-size: 17px;
}


/* =========================================================
   15. VERSION PAGE HELPERS
   ========================================================= */

.roadmap {
    color: var(--text-color);
    background: var(--soft-bg);
}

.roadmap ul {
    text-align: left;
}


/* =========================================================
   16. RESPONSIVE — TABLET
   ========================================================= */

@media (max-width: 900px) {
    .calf-info,
    .cow-info {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sire-info,
    .pasture-info,
    .vaccine-info {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .container {
        width: min(100% - 24px, 1000px);
    }
}


/* =========================================================
   17. RESPONSIVE — PHONE
   ========================================================= */

@media (max-width: 600px) {
    body {
        align-items: stretch;
    }

    .container {
        width: calc(100% - 16px);
        margin: 12px auto 24px;
        padding: 14px;

        border-radius: var(--radius-md);
        box-shadow: var(--shadow-sm);
    }

    h1 {
        font-size: 24px;
    }

    h2 {
        font-size: 20px;
    }

    .theme-toggle,
    .settings-panel,
    .version-button {
        position: static !important;
        display: block;

        width: calc(100% - 16px);
        margin: 8px auto;

        text-align: center;
    }

    .theme-toggle button,
    .settings-panel > button,
    .version-button {
        width: 100%;
    }

    #settings {
        width: 100%;
    }

    .dashboard-section {
        padding: 14px;
    }

    .dashboard-btn-group {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 9px;
    }

    .dashboard-btn {
        width: 100%;
        min-height: 48px;
        padding: 10px;

        font-size: 14px;
    }

    .calves-actions,
    .cows-actions,
    .sires-actions,
    .journal-actions,
    .pasture-actions,
    .vaccines-actions,
    .top-actions,
    .filter-container,
    .action-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .action-filters select,
    .action-filters input,
    .filter-dropdown,
    #cow-search,
    #sire-search {
        width: 100%;
    }

    .cows-actions a,
    .cows-actions form button,
    .sires-actions a,
    .sires-actions form button,
    .journal-actions a,
    .journal-actions form button,
    .vaccines-actions a,
    .vaccines-actions form button {
        max-width: none;
    }

    .cows-actions form input[type="file"],
    .sires-actions form input[type="file"],
    .journal-actions form input[type="file"],
    .vaccines-actions form input[type="file"] {
        max-width: none;
    }

    .calf-item,
    .cow-item,
    .sire-item,
    .journal-item,
    .pasture-item,
    .vaccine-item {
        display: block;
        padding: 14px;
    }

    .calf-info,
    .cow-info,
    .sire-info,
    .journal-info,
    .pasture-info,
    .vaccine-info {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 11px;
    }

    .calf-info strong,
    .cow-info strong,
    .sire-info strong,
    .journal-info strong,
    .pasture-info strong,
    .vaccine-info strong {
        font-size: 15px;
    }

    .calf-info span,
    .cow-info span,
    .sire-info span,
    .journal-info span,
    .pasture-info span,
    .vaccine-info span {
        font-size: 13px;
    }

    .calf-actions,
    .cow-actions,
    .sire-actions,
    .vaccine-actions {
        width: 100%;
        margin-top: 12px;
    }

    .actions-dropdown {
        position: relative;
        width: 100%;
        margin: 0;
    }

    .dropdown-btn {
        width: 100%;
    }

    .dropdown-content {
        display: none;
        position: static;
        width: 100%;
        margin-top: 5px;
    }

    .dropdown-content.show {
        display: block !important;
    }

    form input[type="text"],
    form input[type="date"],
    form input[type="url"],
    form input[type="number"],
    form input[type="email"],
    form input[type="password"],
    form input[type="search"],
    form textarea,
    form select,
    form button {
        font-size: 16px;
    }

    th,
    td {
        padding: 8px;
        font-size: 13px;
    }
}


/* =========================================================
   18. VERY SMALL PHONES
   ========================================================= */

@media (max-width: 380px) {
    .dashboard-btn-group {
        grid-template-columns: 1fr;
    }

    .calf-info,
    .cow-info,
    .sire-info,
    .journal-info,
    .pasture-info,
    .vaccine-info {
        grid-template-columns: 1fr;
    }

    .container {
        width: calc(100% - 10px);
        padding: 10px;
    }
}


/* =========================================================
   19. ACCESSIBILITY
   ========================================================= */

:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
/* Add these rules to styles.css */

.inactive-dialog {
    width: min(92%, 500px);
    padding: 1.5rem;
    border: none;
    border-radius: 12px;
    background: var(--container-bg, #ffffff);
    color: var(--text-color, #222222);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.inactive-dialog::backdrop {
    background: rgba(0, 0, 0, 0.65);
}

.inactive-dialog h2 {
    margin-top: 0;
}

.inactive-dialog form {
    margin: 0;
}

.inactive-dialog select,
.inactive-dialog textarea {
    width: 100%;
    box-sizing: border-box;
}

.dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.flash-messages {
    margin-bottom: 1rem;
}

.flash-message {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    background: rgba(190, 55, 55, 0.12);
    border: 1px solid rgba(190, 55, 55, 0.35);
}

.dashboard-summary{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
    gap:18px;
    margin-bottom:25px;
}

.summary-card{
    padding:22px;
    border-radius:14px;
    background:var(--card-bg);
    text-align:center;
    border:1px solid var(--border-color);
    box-shadow:0 2px 8px rgba(0,0,0,.08);
}

.summary-number{
    font-size:3rem;
    font-weight:700;
    color:var(--accent-color);
}

.summary-title{
    margin-top:8px;
    font-size:1rem;
    font-weight:600;
}