:root {
    /* Brand colors influenced by example-styling */
    --fit-background: #ffffff;
    --fit-foreground: oklch(0.145 0 0);
    --fit-primary: #030213; /* app.css --primary */
    --fit-secondary: #ececf0; /* app.css --secondary approx */
    --fit-secondary-foreground: #030213;
    --fit-accent: #e9ebef;
    --fit-accent-foreground: #030213;
    --fit-muted: #ececf0;
    --fit-muted-foreground: #717182;
    --fit-border: rgba(0, 0, 0, 0.1);
    --fit-success: #16a34a;
    --fit-warning: #ca8a04;
    --fit-danger: #d4183d; /* app.css --destructive */
    --fit-purple: #6f42c1; /* Bootstrap purple */

    /* Override Bootstrap 5.3 CSS variables */
    --bs-body-bg: var(--fit-background);
    --bs-body-color: var(--fit-foreground);
    --bs-primary: var(--fit-primary);
    --bs-secondary: var(--fit-secondary);
    --bs-success: var(--fit-success);
    --bs-warning: var(--fit-warning);
    --bs-danger: var(--fit-danger);
    --bs-info: #2f85ae; /* from example-styling cake.css */
    --bs-border-color: var(--fit-border);
    --bs-link-color: #2f85ae;
    --bs-link-hover-color: #2a6496;
    --bs-border-radius: 0.625rem; /* app.css --radius */
}

/* Typography influenced by example-styling */
body {
    font-size: 14px; /* app.css --font-size */
}
h1, h2, h3, h4, h5, h6 {
    color: #363637; /* cake.css headings */
    font-family: "Raleway", -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

/* Navbar */
.navbar {
    box-shadow: 0 1px 0 var(--fit-border);
}

/* Content containers inspired by cake.css .content */
.content {
    background: #fff;
    padding: 2rem;
    border-radius: 0.625rem;
    box-shadow: 0 7px 14px 0 rgba(60, 66, 87, 0.1), 0 3px 6px 0 rgba(0, 0, 0, 0.07);
}

/* Forms: default inputs styled like Bootstrap when controls lack classes */
.input input,
.input select,
.input textarea {
    display: block;
    width: 100%;
    padding: 0.5rem 0.75rem;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--fit-foreground);
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid var(--fit-border);
    appearance: none;
    border-radius: 0.5rem;
}
.input {
    margin-bottom: 1rem;
}
.error-message {
    color: #991b1b;
    margin-top: 0.25rem;
    font-size: .875rem;
}

.navbar .navbar-brand {
    display: flex;
    align-items: center;
}

.navbar-brand .site-logo {
    height: clamp(24px, 4vw, 56px);
    width: auto;
    display: block; /* avoid baseline gap */
}

/* Buttons influenced by app.css */
.button,
button,
input[type='button'],
input[type='reset'],
input[type='submit'] {
    display: inline-block;
    font-weight: 500;
    color: #fff;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    background-color: var(--fit-primary);
    border: 1px solid var(--fit-primary);
    padding: 0.5rem 1rem;
    font-size: 0.95rem;
    line-height: 1.5;
    border-radius: 0.5rem;
}
.button:hover,
button:hover,
input[type='button']:hover,
input[type='reset']:hover,
input[type='submit']:hover {
    background-color: rgba(3, 2, 19, 0.9);
    border-color: rgba(3, 2, 19, 0.9);
}
.btn-primary {
    background-color: var(--fit-primary);
    border-color: var(--fit-primary);
}
.btn-primary:hover {
    background-color: rgba(3, 2, 19, 0.9);
    border-color: rgba(3, 2, 19, 0.9);
}
.btn-outline-secondary {
    color: var(--fit-foreground);
    border-color: var(--fit-border);
}
.btn-outline-secondary:hover {
    background-color: var(--fit-accent);
    color: var(--fit-accent-foreground);
}

/* Custom purple buttons for Events group */
.btn-purple {
    color: #fff;
    background-color: var(--fit-purple);
    border-color: var(--fit-purple);
}
.btn-purple:hover {
    color: #fff;
    background-color: #5a36a1;
    border-color: #5a36a1;
}
.btn-outline-purple {
    color: var(--fit-purple);
    border-color: var(--fit-purple);
    background-color: transparent;
}
.btn-outline-purple:hover {
    color: #fff;
    background-color: var(--fit-purple);
    border-color: var(--fit-purple);
}

/* Tables */
table {
    width: 100%;
}
table thead th {
    background-color: #f8f9fa;
}
table, th, td {
    border-color: var(--fit-border) !important;
}

/* Paginator styling similar to example-styling */
.paginator { text-align: right; }
.paginator p { margin-bottom: 0; }
.pagination {
    display: flex;
    justify-content: center;
    list-style: none;
    margin: 0 0 1rem 0;
    padding: 0;
}
.pagination li { display: inline-block; margin: 0.25rem; }
.pagination a {
    color: var(--bs-link-color);
    display: inline-block;
    line-height: 2.25rem;
    min-width: 2.25rem;
    padding: 0 0.5rem;
    position: relative;
    text-decoration: none;
}
.pagination li.active a,
.pagination a:hover { text-decoration: underline; }
.pagination .disabled a { cursor: not-allowed; color: var(--fit-muted-foreground); text-decoration: none; }

/* Forms: spacing for default Cake controls; Bootstrap classes added via Form templates */
.mb-3 > .error-message {
    color: #991b1b; /* from cake.css */
    font-size: .875rem;
}

/* Side navigation tweaks */
.side-nav .side-nav-item {
    display: block;
    padding: 0.5rem 0;
}
.side-nav .side-nav-item a {
    text-decoration: none;
}

/* Flash container position similar to example app */
.flash-messages {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1080;
}

/* Utility */
.float-end { float: right; }


