:root {
    --calendar-width: 688px;
    --calendar-mobile-width: 330px;
}

html {
    height: 100%;
    background-color: #fff;
}

body {
    background-color: #fff;
    margin: 0;
    font-family: 'Roboto', Verdana, Geneva, sans-serif;
    font-size: 16px;
    color: #000;
}

.stateMapContainer {
    margin: 20px auto;
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 688px;
}

.map-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
}

#map.statePageMap {
    height: 500px;
    width: 100%;
    max-width: 688px;
    justify-content: center;
    text-align: center;
    display: block !important; /* Override Maps API */
    margin: 0 auto !important; /* Force centering */
}

.stationPageMap {
    height: 500px;
    width: 100%;
    max-width: 688px;
    display: block;
    margin: 0 auto;
}

@media (max-width: 768px) {
    #map.statePageMap {
        height: 400px;
        max-width: 100%;
        width: 100vw !important; /* Force full viewport width */
        margin: 0 auto !important; /* Ensure centering */
    }
    .stationPageMap {
        height: 400px;
        max-width: 100%;
        width: 100vw !important;
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    #map.statePageMap {
        height: 300px;
        max-width: 100%;
        width: 100vw !important; /* Force full viewport width */
        margin: 0 auto !important; /* Ensure centering */
    }
    .stationPageMap {
        height: 300px;
        max-width: 100%;
        width: 100vw !important;
        margin: 0 auto;
    }
}

a {
    color: #000000;
}

a:visited, a:hover, a:active, a:link {
    color: #0282bd;
    text-decoration: none;
}

.heading {
    font-size: 16px;
    text-decoration: none;
}

.logo-box {
    width: 100px;
    border: 0px;
}

h1 {
    font-size: 20px;
    font-weight: bold;
    text-decoration: none;
}

h2 {
    font-size: 16px;
    font-weight: bold;
    text-decoration: none;
    margin: 0;
    padding: 0;
}

h2calheader {
    font-size: 20px;
    font-weight: bold;
    text-decoration: none;
    margin-top: 1.0em;
}

table {
    overflow-x: auto;
    margin: 0;
    padding: 0;
    text-align: center;
}

/* XenForo-inspired Header Styles */
.xf-header {
    background-color: #f0f0f0;
    border-bottom: 1px solid #ddd;
    padding: 10px 15px;
    font-family: Arial, sans-serif;
}

.xf-header-container {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.xf-menu-toggle {
    font-size: 24px;
    cursor: pointer;
    display: none !important; /* Hidden on desktop by default */
}

.xf-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #333;
}

.xf-logo img {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}

.xf-logo .site-title {
    font-size: 20px;
    font-weight: bold;
}

.xf-nav {
    display: flex !important; /* Ensure nav is visible on desktop */
    align-items: center;
    gap: 15px;
}

.xf-link {
    color: #0066cc;
    text-decoration: none;
    font-size: 14px;
}

.xf-link:hover {
    text-decoration: underline;
}

.xf-button {
    background-color: #0066cc;
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.xf-button:hover {
    background-color: #0055b3;
}

.xf-button .icon {
    font-size: 16px;
}

/* Breadcrumb Styling */
.breadcrumb {
    background-color: #fff;
    padding: 8px 15px;
    border-bottom: 1px solid #ddd;
}

.breadcrumb ol {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 5px;
}

.breadcrumb li {
    font-size: 14px;
}

.breadcrumb li a {
    color: #0066cc;
    text-decoration: none;
}

.breadcrumb li a:hover {
    text-decoration: underline;
}

.breadcrumb li:last-child {
    color: #333;
}

/* Responsive Design */
@media (max-width: 767px) {
    .xf-menu-toggle {
        display: block !important; /* Show hamburger menu on mobile */
    }

    .xf-nav {
        display: none !important; /* Hide nav by default on mobile */
        flex-direction: column;
        width: 100%;
        gap: 10px;
        padding: 10px 0;
        background-color: #f0f0f0;
    }

    .xf-header-container {
        flex-wrap: wrap;
    }

    .xf-nav.active {
        display: flex !important; /* Show nav when toggled on mobile */
    }
}

#content {
    margin: 0;
}

.top_banner {}

.blue {
    color: #0282bd;
}

.gray {
    color: #9E9F63;
}

.pmoon {
    position: absolute;
    border: none;
    margin: 0;
}

#state_links {
    line-height: 16px;
}

div#tipDiv {
    position: absolute;
    visibility: hidden;
    top: 0;
    z-index: 10000;
    background-color: #FFFFFF;
    border: 1px solid #336;
    width: 240px;
    padding: 4px;
    color: #000;
    font-family: Verdana, Geneva, sans-serif;
    font-size: 16px;
}

div.tp1 {
    color: #FFFFFF;
    font-style: normal;
}

div.tp2 {
    color: #0282bd;
    font-size: 18px;
}

.tip {
    font-family: Arial, Helvetica, sans-serif;
}

.difcol {
    font-size: 9px;
    color: #000000;
    text-align: center;
    background-color: #EAEAEA;
}

.colheaders {
    background-color: #989898;
    color: #000000;
    text-align: center;
    display: block;
    margin: 0 auto;
    overflow-x: auto;
}

.tide_calendar {
    margin: 0;
    overflow-x: auto;
    border-collapse: collapse;
    display: block;
    max-width: -moz-fit-content;
    max-width: fit-content;
}

.tide_titles1, .tide_titles2 {
    font-size: 16px;
    background-color: #E4E4E4;
    color: #000000;
}

.tide_titles2 {
    text-align: right;
}

.graph {
    width: 96px;
    height: 0%;
}

.smgraph-box {
    width: 96px;
    border: 0px;
}

.tides-box {
    display: block;
    border: 0px;
    max-width: 688px;
    margin: 10px 0;
    color: #000000;
}

.smgraph-box img {
    display: block;
}

.tidewidth {}

#month_nav {}

#month_nav td {
    text-align: center;
}

#month_nav a {
    word-spacing: 0px;
    display: block;
    margin: 0;
}

table.tide_calendar_head {
    border: none;
    border-collapse: collapse;
    background-color: #F2F5F9;
}

table.tide_calendar_head TD {
    border: 1px solid #000000;
}

table.tide_calendar {
    border: none;
    border-collapse: collapse;
    border-spacing: 0px;
}

.calendar_width {}

table.tide_calendar h2 {
    margin-top: 15px;
}

table.tide_calendar TR.even {
    background-color: #FFFFFF;
    text-align: center;
}

table.tide_calendar TR.odd {
    background-color: #F2F5F9;
    text-align: center;
}

table.tide_calendar TH {
    border: 2px solid #000000;
    background-color: #CCCCCC;
    width: 96px;
    height: 30px;
    font-size: 14px;
}

table.tide_calendar TD {
    border: 2px solid #000000;
    width: 96px;
    height: 96px;
}

table.tide_calendar TD.diff {
    background-color: #EBEBEB;
    text-align: center;
}

table.outside_table {
    border: 2px solid #000000;
}

table.tide_stats {
    border: none;
}

table.tide_stats TD {
    white-space: nowrap;
}

table.tide_stats TR.even {
    background-color: #FFFFFF;
}

.wrap_textual_details {
    margin: 0;
}

div#menu {
    padding-top: 0;
}

ul#tabs a {
    float: left;
    width: 101px;
    padding: 0;
    text-decoration: none;
    background: #858558;
    color: #FFFFFF;
}

ul#tabs li.activelink a, ul#tabs a:hover {
    color: #FFFFFF;
}

.dayView.threeDays .hideIf {
    display: none;
}

.dayView.threeDays h1 {
    font-size: 1.5em;
    font-weight: bold;
}

.dayViewNavLinks {
    margin-bottom: 1em;
}

.dayViewCharts {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.dayView.threeDays .dayViewCharts {
    margin-top: 1em;
}

.dayViewChart {
    margin: 5px;
}

.dayView.threeDays .dayViewChart {
    cursor: pointer;
}

.blurredText {
    filter: blur(4px);
}

.blurredTable, .blurredText {
    cursor: pointer;
}

.blurredGraphLock {
    position: relative;
}

.blurredGraphLock .lockOverlay {
    position: absolute;
    top: 50%;
    left: 50%;
    color: #EBEBEB;
    opacity: 0.75;
    transform: translate(-50%, -50%);
}

.bizCalendarHeader {
    display: flex;
    width: var(--calendar-width);
    margin-bottom: -4px;
    font-size: 1.3em;
}

.bizCalendarHeader.mobileView {
    flex-direction: column;
    align-items: center;
    width: var(--calendar-mobile-width);
}

.bizCalendarHeader.tableView {
    justify-content: center;
}

.bizCalendarHeader h1 {
    font-size: 1.4em;
    line-height: 1.0em;
}

.bizCalendarHeader .logo-box {
    position: relative;
}

.bizCalendarHeader .logo-box .station-id {
    position: absolute;
    top: 3px;
    left: 50%;
    transform: translateX(-50%);
}

.bizCalendarHeader .logo-box .station-id a,
.bizCalendarHeader .logo-box .station-id a:link,
.bizCalendarHeader .logo-box .station-id a:visited,
.bizCalendarHeader .logo-box .station-id a:active,
.bizCalendarHeader .logo-box .station-id a:hover {
    color: #999;
    text-decoration: underline;
}

.bizCalendarHeader .logoQr {
    display: flex;
    min-width: 211px;
}

.bizCalQrCode div {
    width: 99px;
    margin-top: -10px;
    padding-bottom: 5px;
    background-color: #fff;
}

.bizCalendarHeader img[src$="/tides100.png"] {
    width: 100px;
    margin: 0;
}

.bizCalTitleDate {
    margin: 5px 0 0 20px;
    font-size: 0.9em;
    text-align: left;
}

.mobileView .bizCalTitleDate {
    text-align: center;
}

.bizCalTitleName {
    font-size: 24px;
    margin-top: 5px;
}

.bizCalTitleState {
    font-size: 0.85em;
}

.textDetails {
    display: inline;
}

.stationPageNav {
    margin-bottom: 20px;
}

.stationPageTabs {
    margin-top: 40px;
    color: #06C;
}

.stationPageTabs .tabHeaders {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    color: #06C;
}

.stationPageTabs .tabHeader a {
    cursor: pointer;
}

.stationPageTabs .tabContents {
    margin-top: 20px;
    color: #06F;
}

.stationPageTabs .tabContent {
    min-height: 1500px;
    display: none;
    color: #06F;
}

.stationPageTabs .tabContent.active {
    display: block;
}

#dayChartInset {
    display: flex;
    margin-bottom: 20px;
    justify-content: center;
}

#dayChartInset > div {
    width: var(--calendar-width);
    display: none;
}

#dayChartInset.mobileView > div {
    width: 318px;
}

#dayChartInset .insetCurrent {
    display: block;
}

#dayChartInsetWrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

#dayChartInsetWrapper .insetIcon {
    cursor: pointer;
    padding: 10px;
}

.dayChartInsetTitle {
    margin-bottom: 5px;
}

table.tide_calendar {
    background-color: #fff;
}

.memberData {
    margin-top: 20px;
}

.memberDataShow {
    width: var(--calendar-width);
    margin-top: 15px;
    display: none;
}

.memberDataShow.mobileView {
    width: var(--calendar-mobile-width);
}

.memberEditForm {
    margin-top: 15px;
    width: 400px;
}

.memeberDataEditRow {
    display: flex;
    margin-bottom: 5px;
}

.memberDataEditRowTitleAndTip {
    text-align: left;
    width: 150px;
    min-width: 150px;
    font-weight: bold;
}

.memberDataEditRowTip {
    font-weight: normal;
    font-size: 0.85em;
}

.memberDataRowInput {}

.memberDataEditButton {
    cursor: pointer;
}

.memberDataTitle {
    margin-top: 20px;
    font-size: 2.2em;
    font-weight: bold;
}

.memberDataLocation {
    font-size: 1.3em;
    font-weight: bold;
}

.tableWidth {
    max-width: var(--calendar-width);
}

@media (max-width: 480px) {
    .tableWidth {
        max-width: var(--calendar-mobile-width);
    }
    .bizCalendarHeader .logoQr {
        display: none;
    }
    .memberEditForm {
        padding-left: 10px;
        max-width: 350px;
    }
    .memberDataEditRowTitleAndTip {
        width: 120px;
        min-width: 120px;
    }
}

/* Tide table styles */
table.tide_stats {
    border: none;
    border-collapse: collapse;
    border-spacing: 0;
    font-size: 12px;
}

table.tide_stats th {
    background-color: #E8E8E8; /* Light gray for header row */
    padding: 2px 2px; /* Reduced padding for header cells */
    line-height: 1.2;
    vertical-align: middle;
}

table.tide_stats TD {
    white-space: nowrap;
    padding: 2px 2px; /* Reduced padding to minimize column spacing */
    line-height: 1.2;
    margin: 0;
    vertical-align: middle;
}

table.tide_stats TR {
    line-height: 1.2;
    height: auto;
}

table.tide_stats TR.even {
    background-color: #FFFFFF; /* White for even rows */
}

table.tide_stats TR.odd {
    background-color: #F5F5F5; /* Light gray for odd rows */
}

/* Highlight diff columns */
table.tide_stats th.diff,
table.tide_stats td.diff {
    background-color: #FFFFCC; /* Light yellow for diff columns */
}

/* Print-specific styles for tide table */
@media print {
    table.tide_stats {
        border-collapse: collapse !important;
        border-spacing: 0 !important;
        font-size: 10pt !important;
    }
    table.tide_stats th {
        background-color: #E8E8E8 !important; /* Preserve header color in print */
        padding: 1px 1px !important; /* Reduced padding for print */
        line-height: 1.2 !important;
        vertical-align: middle !important;
    }
    table.tide_stats tr {
        line-height: 1.2 !important;
        height: auto !important;
    }
    table.tide_stats td {
        padding: 1px 1px !important; /* Reduced padding for print */
        margin: 0 !important;
        line-height: 1.2 !important;
        vertical-align: middle !important;
    }
    /* Ensure alternating colors are visible in print */
    table.tide_stats TR.even {
        background-color: #FFFFFF !important;
    }
    table.tide_stats TR.odd {
        background-color: #F5F5F5 !important;
    }
    /* Preserve diff column highlight in print */
    table.tide_stats th.diff,
    table.tide_stats td.diff {
        background-color: #FFFFCC !important;
    }
}

/* Existing print styles for calendar table (unchanged) */
@media print {
    .print_adjust_margin {
        margin: 0;
        text-align: center;
    }
    .noPrint {
        display: none !important;
    }
    .stationPageTabs .tabContent.showInPrint {
        display: block !important;
        min-height: unset;
        font-weight: normal;
        color: #09F;
    }
    .header {
        display: none;
    }
    table.tide_calendar {
        width: 720px !important;
        height: 576px !important;
        margin: 0 auto !important;
        border-collapse: collapse !important;
        border-spacing: 0 !important;
        table-layout: fixed !important;
        min-height: 576px !important;
        max-height: 576px !important;
    }
    table.tide_calendar th.tide_calendar_header {
        width: 102.86px !important;
        height: 96px !important;
        min-height: 96px !important;
        max-height: 96px !important;
        font-size: 16px !important;
        border: 2px solid #000000 !important;
        line-height: 96px !important;
        vertical-align: middle !important;
        padding: 0 !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }
    table.tide_calendar td {
        width: 102.86px !important;
        height: 96px !important;
        min-height: 96px !important;
        max-height: 96px !important;
        border: 2px solid #000000 !important;
        padding: 0 !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }
    table.tide_calendar td img {
        width: 102.86px !important;
        height: 96px !important;
        min-height: 96px !important;
        max-height: 96px !important;
        display: block !important;
        object-fit: contain !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    .bizCalendarHeader {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        margin: 0 auto !important;
        padding: 0 !important;
        width: 720px !important;
        height: 100px !important;
        min-height: 100px !important;
        max-height: 100px !important;
    }
    .bizCalendarHeader .logoQr {
        margin: 0 !important;
        padding: 0 !important;
        height: 100px !important;
        min-height: 100px !important;
        max-height: 100px !important;
    }
    .bizCalendarHeader .logoQr img {
        margin: 0 !important;
        padding: 0 !important;
    }
    .bizCalendarHeader .bizCalTitleName {
        font-size: 16pt !important;
        margin: 0 !important;
        padding: 0 !important;
        line-height: 1 !important;
    }
    .bizCalendarHeader .bizCalTitleName h2 {
        margin: 0 !important;
        padding: 0 !important;
    }
}