/* Custom CSS for Stone Brook Community Association Portal */

:root {
    --sb-ink: #172033;
    --sb-muted: #64748b;
    --sb-line: #d9e2ec;
    --sb-surface: #f7fafc;
    --sb-panel: #ffffff;
    --sb-primary: #246b5a;
    --sb-primary-dark: #16493e;
    --sb-accent: #d89b35;
    --sb-blue: #315f8c;
    --sb-shadow: 0 18px 45px rgba(23, 32, 51, 0.10);
}

html {
    background: var(--sb-surface);
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    color: var(--sb-ink);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 250, 252, 0.96)),
        var(--sb-surface);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

a:hover {
    color: var(--sb-primary-dark);
}

.btn {
    border-radius: 7px;
    font-weight: 650;
}

.btn-primary {
    background-color: var(--sb-primary);
    border-color: var(--sb-primary);
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--sb-primary-dark);
    border-color: var(--sb-primary-dark);
}

.btn-outline-primary {
    color: var(--sb-primary);
    border-color: var(--sb-primary);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: var(--sb-primary);
    border-color: var(--sb-primary);
}

.site-masthead {
    position: relative;
    z-index: 10;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(217, 226, 236, 0.9);
    box-shadow: 0 8px 30px rgba(23, 32, 51, 0.06);
}

.site-nav {
    min-height: 76px;
}

.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--sb-ink);
}

.site-brand:hover {
    color: var(--sb-ink);
}

.site-brand-mark {
    display: inline-grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 7px;
    color: #fff;
    background: linear-gradient(135deg, var(--sb-primary), var(--sb-blue));
    font-weight: 800;
    letter-spacing: 0;
}

.site-brand-name,
.site-brand-subtitle {
    display: block;
    line-height: 1.05;
}

.site-brand-name {
    font-weight: 800;
    font-size: 1.08rem;
}

.site-brand-subtitle {
    color: var(--sb-muted);
    font-size: 0.78rem;
}

.site-nav .nav-link {
    color: #334155;
    font-weight: 650;
    border-radius: 7px;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.site-nav .nav-link:hover,
.site-nav .nav-link:focus {
    color: var(--sb-primary);
    background: #edf7f4;
}

.dropdown-menu {
    border-color: var(--sb-line);
    border-radius: 8px;
    box-shadow: var(--sb-shadow);
}

.dropdown-item {
    padding-top: 0.55rem;
    padding-bottom: 0.55rem;
}

.page-shell {
    width: 100%;
    padding-top: 2rem;
    padding-bottom: 4rem;
}

.site-footer {
    margin-top: auto;
    padding: 1rem 0;
    color: #475569;
    background: #eef3f7;
    border-top: 1px solid var(--sb-line);
    font-size: 0.95rem;
}

.home-page {
    flex: 1;
}

.home-hero {
    min-height: 520px;
    display: flex;
    align-items: stretch;
    color: #fff;
    background-image:
        linear-gradient(90deg, rgba(13, 32, 45, 0.76), rgba(13, 32, 45, 0.42), rgba(13, 32, 45, 0.12)),
        url("../images/fountain.4a0e07c1e4f2.jpg");
    background-size: cover;
    background-position: center;
}

.home-hero-inner {
    display: flex;
    align-items: center;
    padding-top: 4rem;
    padding-bottom: 4rem;
}

.home-hero-copy {
    width: min(680px, 100%);
}

.eyebrow {
    margin-bottom: 0.8rem;
    color: var(--sb-accent);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

.home-hero h1 {
    max-width: 720px;
    margin-bottom: 1rem;
    font-size: 5.5rem;
    line-height: 0.95;
    font-weight: 850;
}

.home-hero-lede {
    max-width: 620px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.25rem;
    line-height: 1.55;
}

.home-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.8rem;
}

.home-section {
    padding-top: 3rem;
    padding-bottom: 3rem;
}

.home-alert-wrap {
    margin-top: -2rem;
    position: relative;
    z-index: 2;
}

.site-alert-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.2rem;
    color: #fff;
    background: linear-gradient(135deg, var(--sb-primary-dark), var(--sb-blue));
    border-radius: 8px;
    box-shadow: var(--sb-shadow);
}

.site-alert-banner strong,
.site-alert-banner span {
    display: block;
}

.site-alert-banner strong {
    font-size: 1.02rem;
}

.site-alert-banner span {
    color: rgba(255, 255, 255, 0.86);
}

.quick-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: -5.5rem;
}

.quick-action {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding: 1.5rem;
    color: var(--sb-ink);
    text-decoration: none;
    background: var(--sb-panel);
    border: 1px solid rgba(217, 226, 236, 0.9);
    border-radius: 8px;
    box-shadow: var(--sb-shadow);
}

.quick-action:hover {
    color: var(--sb-ink);
    transform: translateY(-2px);
    border-color: rgba(36, 107, 90, 0.34);
}

.quick-action strong {
    font-size: 1.2rem;
}

.quick-action span:last-child {
    color: var(--sb-muted);
}

.quick-action-kicker {
    color: var(--sb-primary);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.74fr);
    gap: 2rem;
    align-items: start;
}

.home-grid h2 {
    max-width: 620px;
    font-size: 3.25rem;
    line-height: 1;
    font-weight: 820;
}

.home-grid p:not(.eyebrow) {
    max-width: 620px;
    color: var(--sb-muted);
    font-size: 1.08rem;
    line-height: 1.7;
}

.resource-panel {
    padding: 1.4rem;
    background: #fff;
    border: 1px solid var(--sb-line);
    border-radius: 8px;
    box-shadow: 0 14px 35px rgba(23, 32, 51, 0.07);
}

.resource-panel h3 {
    margin-bottom: 0.9rem;
    font-size: 1.2rem;
    font-weight: 800;
}

.resource-panel .list-group-item {
    padding-left: 0;
    padding-right: 0;
    border-color: var(--sb-line);
    font-weight: 650;
}

.resource-panel .list-group-item span {
    display: block;
    margin-top: 0.2rem;
    color: var(--sb-muted);
    font-size: 0.92rem;
    font-weight: 400;
}

.home-news-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
    gap: 1.2rem;
}

.home-panel {
    padding: 1.4rem;
    background: #fff;
    border: 1px solid var(--sb-line);
    border-radius: 8px;
    box-shadow: 0 14px 35px rgba(23, 32, 51, 0.07);
}

.home-panel h2,
.section-heading-row h2 {
    margin-bottom: 1rem;
    font-size: 1.65rem;
    font-weight: 820;
}

.section-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.event-list,
.document-highlight-list,
.compact-event-list {
    display: grid;
    gap: 0.75rem;
}

.event-item,
.document-highlight,
.compact-event {
    display: grid;
    gap: 0.45rem;
    padding: 1rem;
    color: var(--sb-ink);
    text-decoration: none;
    background: var(--sb-surface);
    border: 1px solid var(--sb-line);
    border-radius: 8px;
}

.event-item {
    grid-template-columns: 90px 1fr;
}

.event-date {
    display: grid;
    align-content: center;
    justify-items: center;
    min-height: 72px;
    color: #fff;
    background: var(--sb-primary);
    border-radius: 7px;
}

.event-date span,
.document-highlight span,
.compact-event em,
.dashboard-action em,
.muted-copy {
    color: var(--sb-muted);
    font-style: normal;
}

.event-item h3,
.document-highlight strong,
.compact-event strong {
    margin: 0;
    font-size: 1.02rem;
}

.dashboard-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.6rem;
    color: #fff;
    background:
        linear-gradient(90deg, rgba(13, 32, 45, 0.82), rgba(36, 107, 90, 0.72)),
        url("../images/fountain.4a0e07c1e4f2.jpg");
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    box-shadow: var(--sb-shadow);
}

.dashboard-hero .eyebrow,
.dashboard-hero p {
    color: rgba(255, 255, 255, 0.86);
}

.dashboard-hero h1 {
    margin-bottom: 0.45rem;
    font-size: 2.2rem;
    font-weight: 820;
}

.dashboard-alert {
    margin-bottom: 1.2rem;
}

.dashboard-quick-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
    margin-bottom: 1.6rem;
}

.dashboard-action {
    min-height: 150px;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 1rem;
    color: var(--sb-ink);
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--sb-line);
    border-radius: 8px;
    box-shadow: 0 10px 28px rgba(23, 32, 51, 0.05);
}

.dashboard-action:hover,
.document-highlight:hover,
.compact-event:hover {
    color: var(--sb-ink);
    border-color: rgba(36, 107, 90, 0.34);
}

.dashboard-action span {
    color: var(--sb-primary);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.dashboard-action strong {
    font-size: 1.1rem;
}

.compact-event {
    grid-template-columns: 54px 1fr;
    align-items: center;
}

.compact-event span {
    color: var(--sb-primary);
    font-weight: 800;
}

.document-highlight-list.compact .document-highlight {
    padding: 0.75rem;
}

.pool-hero-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    color: #fff;
    background:
        linear-gradient(90deg, rgba(13, 32, 45, 0.78), rgba(49, 95, 140, 0.55)),
        url("../images/SBPool.30e08c408d4e.jpg");
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    box-shadow: var(--sb-shadow);
}

.pool-hero-panel .eyebrow,
.pool-hero-panel p {
    color: rgba(255, 255, 255, 0.88);
}

.pool-hero-panel h1 {
    font-size: 2.4rem;
    font-weight: 820;
}

.pool-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.pool-key-card {
    border-color: rgba(36, 107, 90, 0.38);
}

.card,
.rounded-3 {
    border-radius: 8px !important;
}

.card {
    border-color: var(--sb-line);
    box-shadow: 0 10px 28px rgba(23, 32, 51, 0.05);
}

.site-header-custom {
    /* Placeholder for your fountain image - update 'fountain.jpg' as needed */
    background-image: linear-gradient(rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.25)), url("../images/fountain.4a0e07c1e4f2.jpg"); /* Reduced overlay opacity from 0.4 to 0.25 */
    background-size: cover;
    background-position: center center;
}

.site-tagline {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; /* Standard professional sans-serif stack */
    font-size: 1rem; /* Standard paragraph size, or smaller e.g., 0.9rem */
    font-weight: 300; /* Lighter weight for a more refined look */
    opacity: 0.85; /* Slightly subtle */
    margin-top: 0.5rem; /* Add a little space below the main heading */
}

.bg-custom-navbar-footer {
    background-color: #F5F7FB !important; /* Updated to new hex color */
}

/* Add more custom styles below as needed */

/* Responsive images within announcement content (CKEditor output) */
.card-body div img {
    max-width: 300px;  /* Adjust as needed for "much smaller" initial display */
    max-height: 250px; /* Adjust as needed */
    width: auto;       /* Maintain aspect ratio */
    height: auto;      /* Maintain aspect ratio */
    display: block; 
    margin-left: auto; 
    margin-right: auto;
    cursor: pointer;   /* Suggests clickability; relies on image being linked */
    transition: transform 0.2s ease-in-out; /* Optional: slight visual feedback on hover */
}

/* Optional: slight zoom effect on hover if the image is meant to be clickable */
.card-body div a:has(> img:hover) img, /* If image is wrapped in a link */
.card-body div img:hover { /* If image itself is interactive (less likely without JS for modal) */
    /* transform: scale(1.05); */ /* Commented out, can be too much */
}

.btn-owner-resource {
    min-width: 220px; /* Adjust this value as needed for desired button width */
    text-align: center; /* Ensures text is centered within the button */
    /* You can add specific padding or margin here if needed, e.g. */
    /* padding-top: 0.75rem; */
    /* padding-bottom: 0.75rem; */
}

/* Calendar Styles */
.calendar-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed; /* Ensures columns are equal width */
}

.calendar-table th, .calendar-table td {
    border: 1px solid #e0e0e0;
    padding: 8px;
    text-align: center;
    vertical-align: top;
    height: 100px; /* Fixed height for each day cell */
    position: relative;
}

.calendar-table th {
    background-color: #f8f9fa;
    font-weight: bold;
}

.calendar-day {
    background-color: #ffffff;
}

.calendar-day.disabled {
    background-color: #f0f0f0;
    color: #ccc;
    cursor: not-allowed;
}

.calendar-day.today {
    border: 2px solid #007bff;
}

.calendar-day.available {
    cursor: pointer;
}

.calendar-day.available:hover {
    background-color: #e9ecef;
}

.calendar-day.booked { /* This class is now primarily for text color/general booked state */
    color: #888;
}

.calendar-day.fully-booked {
    background-color: #ffdddd; /* Light red for fully booked */
}

/* New style for off-season bookable dates */
.calendar-day.off-season-bookable {
    background-color: #fffacd; /* Light yellow */
    color: #5a5a5a; /* Darker text for readability on yellow */
    cursor: pointer;
}

.calendar-day.off-season-bookable:hover {
    background-color: #ffe8a1; /* Slightly darker yellow on hover */
}

.calendar-day .day-number {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 5px;
    color: #333;
}

.calendar-day.disabled .day-number,
.calendar-day.booked .day-number {
    color: #aaa;
}

.calendar-day.off-season-bookable .day-number {
    color: #8B4513; /* Brownish color for off-season day numbers */
}

.slot-info {
    font-size: 0.85em;
    line-height: 1.3;
    color: #666;
}

.calendar-day.booked .slot-info {
    color: #888;
}

.calendar-day.off-season-bookable .slot-info {
    color: #6B8E23; /* Olive green for off-season slot info */
}

/* Calendar navigation header */
.calendar-nav-header {
    padding: 1rem;
    background-color: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
}

#currentMonthYear {
    font-size: 1.5rem;
    font-weight: bold;
}

/* Modal styles for booking form */
#bookingModal .modal-body {
    padding: 20px;
}

#bookingModal .modal-footer {
    border-top: none;
    padding-top: 0;
}

/* Adjustments for small screens */
@media (max-width: 768px) {
    .site-nav {
        min-height: auto;
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    .site-account .btn {
        width: 100%;
    }

    .home-hero {
        min-height: 460px;
        background-image:
            linear-gradient(180deg, rgba(13, 32, 45, 0.82), rgba(13, 32, 45, 0.5)),
            url("../images/fountain.4a0e07c1e4f2.jpg");
    }

    .home-hero-inner {
        padding-top: 3rem;
        padding-bottom: 7rem;
    }

    .home-hero h1 {
        font-size: 3rem;
    }

    .home-grid h2 {
        font-size: 2.15rem;
    }

    .home-hero-lede {
        font-size: 1.04rem;
    }

    .quick-actions,
    .home-grid,
    .home-news-grid,
    .dashboard-quick-grid,
    .pool-info-grid {
        grid-template-columns: 1fr;
    }

    .quick-actions {
        margin-top: -4.5rem;
    }

    .quick-action {
        min-height: auto;
    }

    .site-alert-banner,
    .dashboard-hero,
    .pool-hero-panel {
        align-items: stretch;
        flex-direction: column;
    }

    .event-item,
    .compact-event {
        grid-template-columns: 1fr;
    }

    .calendar-table th, .calendar-table td {
        padding: 4px;
        height: 80px;
        font-size: 0.8em;
    }
    .calendar-day .day-number {
        font-size: 1em;
    }
    .slot-info {
        font-size: 0.75em;
    }
}
