/* =====================================================================
   SDFM — Sitewide CSS
   Cleaned & Consolidated Version
   ===================================================================== */

/* =========================================================
   Base Typography
   ========================================================= */

body {
    font-family: 'Raleway', sans-serif;
}

/* Ensure FullCalendar uses site font */
.fc {
    font-family: 'Raleway', sans-serif;
}

/* =========================================================
   HEADER – Slim Dropdown Adjustments
   ========================================================= */

nav#primary-nav ul.dropdown-menu > li > a,
nav#primary-nav ul.sub-menu > li > a {
    padding: 4px 10px !important;
    line-height: 1.1 !important;
    font-size: 13px !important;
    height: auto !important;
    display: block;
    white-space: nowrap;
}

nav#primary-nav ul.dropdown-menu,
nav#primary-nav ul.sub-menu {
    padding-top: 2px !important;
    padding-bottom: 2px !important;
}

nav#primary-nav ul.dropdown-menu > li {
    padding: 0 !important;
}

/* =========================================================
   Membership Banner Height Override
   ========================================================= */

body section.banner.banner-secondary#top {
    height: 260px !important;
    min-height: 260px !important;
    padding: 40px 0 !important;
    background-size: cover !important;
    background-position: center !important;
}

body section.banner.banner-secondary#top .banner-caption {
    padding: 20px 0 !important;
}

/* =========================================================
   CMS Embedded Media Cleanup (TinyMCE / Vimeo)
   ========================================================= */

.cms-content iframe,
.cms-content video {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 20px 0 !important;
    display: block !important;
    max-width: 100% !important;
}

.cms-content iframe[src*="vimeo.com"] {
    width: 100% !important;
    aspect-ratio: 16 / 9 !important;
    height: auto !important;
}

/* =========================================================
   Header Layout (Legacy Stable Version)
   ========================================================= */

.sdfm-header {
    background: #fff;
}

.sdfm-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.sdfm-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

.logo {
    width: 30 px;
    height: 60px;
    background: url('/img/logo.png') no-repeat left center;
    background-size: contain;
}


#header .col-md-12 {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 5px;
    padding-left: 35px;
    padding-right: 35px;
}

.logo {
    flex: 0 0 auto;
}

#primary-nav {
    flex: 1;
}

/* =========================================================
   Desktop Navigation
   ========================================================= */

.sdfm-nav {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.sdfm-menu {
    display: flex;
    flex-wrap: nowrap;
    white-space: nowrap;
    gap: 26px;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.sdfm-menu > li {
    position: relative;
}

.sdfm-menu > li > a,
.sdfm-dropdown-toggle {
    color: #222;
    text-decoration: none;
    font-size: 15px;
    line-height: 1;
    padding: 6px 0;
    display: inline-block;
}

.sdfm-menu > li > a:hover,
.sdfm-dropdown-toggle:hover {
    text-decoration: underline;
}

/* Dropdown Caret */
.sdfm-dropdown-toggle::after {
    content: " ▼";
    font-size: 11px;
    margin-left: 6px;
    vertical-align: middle;
}

/* Dropdown Menu */
.sdfm-submenu {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 10px;
    min-width: 240px;
    background: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    list-style: none;
    padding: 8px 0;
    z-index: 9999;
}

.sdfm-dropdown:hover .sdfm-submenu {
    display: block;
}

.sdfm-submenu li a {
    display: block;
    padding: 8px 14px;
    color: #222;
    text-decoration: none;
    font-size: 14px;
}

.sdfm-submenu li a:hover {
    background: #f3f3f3;
}

/* =========================================================
   Filmstrip
   ========================================================= */

.sdfm-filmstrip {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.sdfm-filmstrip img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================================
   Mobile Navigation
   ========================================================= */

#primary-nav-button {
    display: none;
}

@media (max-width: 900px) {

    #primary-nav-button {
        display: inline-block;
        background: #3b6edb;
        color: #fff;
        border: none;
        padding: 8px 14px;
        border-radius: 4px;
        cursor: pointer;
    }

    .sdfm-menu {
        display: none;
        flex-direction: column;
        gap: 0;
        width: 100%;
        margin-top: 10px;
    }

    .sdfm-menu.active {
        display: flex;
    }

    .sdfm-menu > li > a,
    .sdfm-dropdown-toggle {
        padding: 10px 0;
    }
}

/* =========================================================
   Calendar Layout
   ========================================================= */

#calendar {
    max-width: 800px;
    margin: 0 auto;
}

/* Legend */

.calendar-legend {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 10px 0 15px 0;
    font-size: 13px;
    flex-wrap: wrap;
}

.calendar-legend .legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.calendar-legend .legend-colour {
    width: 12px;
    height: 12px;
    border-radius: 2px;
    border: 1px solid #555;
    display: inline-block;
}

/* =========================================================
   Calendar Event Detail Page
   ========================================================= */

.calendar-event-card {
    background: #fff;
    padding: 25px;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    margin-top: 20px;
}

.calendar-event-title {
    margin-top: 0;
    font-weight: 400;
}

.calendar-event-meta {
    display: block;
}

.calendar-event-date,
.calendar-event-category {
    font-size: 14px;
}

.category-badge {
    display: inline-block;
    padding: 4px 10px;
    color: #fff;
    border-radius: 3px;
    font-size: 13px;
}

.calendar-event-notes {
    margin-top: 15px;
    font-size: 14px;
    line-height: 1.6;
}

/* Calendar admin compact inputs */
.calendar-admin .form-control,
.calendar-admin input[type="datetime-local"].form-control {
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
  padding: 4px 8px !important;
  font-size: 13px !important;
  box-sizing: border-box !important;
}

.calendar-admin label {
  margin-bottom: 4px;
}

.calendar-admin .form-group {
  margin-bottom: 12px;
}

/* Make Calendarbadmin form compact */
.member-home .form-control.input-sm {
    height: 30px;
    padding: 4px 8px;
    font-size: 13px;
}

.member-home label {
    font-size: 13px;
    margin-bottom: 4px;
}

.member-home .form-group {
    margin-bottom: 12px;
}


/* =========================================================
   HEADER2DEV MENU SWITCHING
========================================================= */

/* ---------------------------------------------------------
   DEFAULT
   Standard menu visible
--------------------------------------------------------- */

.header2dev .menu-standard {
    display: block !important;
}

.header2dev .menu-xl {
    display: none !important;
}


/* ---------------------------------------------------------
   EXTRA LARGE (1400+)
--------------------------------------------------------- */

@media screen and (min-width: 1400px) {

    .header2dev .menu-standard {
        display: none !important;
    }

    .header2dev .menu-xl {
        display: block !important;
    }
}


/* =========================================================
   STANDARD MENU LAYOUT
========================================================= */

/* =====================================================================
   SDFM — Sitewide CSS
   Cleaned & Consolidated Version
   ===================================================================== */

/* =========================================================
   Base Typography
   ========================================================= */

body {
    font-family: 'Raleway', sans-serif;
}

/* Ensure FullCalendar uses site font */
.fc {
    font-family: 'Raleway', sans-serif;
}

/* =========================================================
   HEADER – Slim Dropdown Adjustments
   ========================================================= */

nav#primary-nav ul.dropdown-menu > li > a,
nav#primary-nav ul.sub-menu > li > a {
    padding: 4px 10px !important;
    line-height: 1.1 !important;
    font-size: 13px !important;
    height: auto !important;
    display: block;
    white-space: nowrap;
}

nav#primary-nav ul.dropdown-menu,
nav#primary-nav ul.sub-menu {
    padding-top: 2px !important;
    padding-bottom: 2px !important;
}

nav#primary-nav ul.dropdown-menu > li {
    padding: 0 !important;
}

/* =========================================================
   Membership Banner Height Override
   ========================================================= */

body section.banner.banner-secondary#top {
    height: 260px !important;
    min-height: 260px !important;
    padding: 40px 0 !important;
    background-size: cover !important;
    background-position: center !important;
}

body section.banner.banner-secondary#top .banner-caption {
    padding: 20px 0 !important;
}

/* =========================================================
   CMS Embedded Media Cleanup (TinyMCE / Vimeo)
   ========================================================= */

.cms-content iframe,
.cms-content video {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 20px 0 !important;
    display: block !important;
    max-width: 100% !important;
}

.cms-content iframe[src*="vimeo.com"] {
    width: 100% !important;
    aspect-ratio: 16 / 9 !important;
    height: auto !important;
}

/* =========================================================
   Header Layout (Legacy Stable Version)
   ========================================================= */

.sdfm-header {
    background: #fff;
}

.sdfm-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.sdfm-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

.logo {
    width: 180px;
    height: 60px;
    /*background: url('/img/logo.png') no-repeat left center; */
    background-size: contain;
}

/* =========================================================
   Desktop Navigation
   ========================================================= */

.sdfm-nav {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.sdfm-menu {
    display: flex;
    flex-wrap: nowrap;
    white-space: nowrap;
    gap: 26px;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.sdfm-menu > li {
    position: relative;
}

.sdfm-menu > li > a,
.sdfm-dropdown-toggle {
    color: #222;
    text-decoration: none;
    font-size: 15px;
    line-height: 1;
    padding: 6px 0;
    display: inline-block;
}

.sdfm-menu > li > a:hover,
.sdfm-dropdown-toggle:hover {
    text-decoration: underline;
}

/* Dropdown Caret */
.sdfm-dropdown-toggle::after {
    content: " ▼";
    font-size: 11px;
    margin-left: 6px;
    vertical-align: middle;
}

/* Dropdown Menu */
.sdfm-submenu {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 10px;
    min-width: 240px;
    background: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    list-style: none;
    padding: 8px 0;
    z-index: 9999;
}

.sdfm-dropdown:hover .sdfm-submenu {
    display: block;
}

.sdfm-submenu li a {
    display: block;
    padding: 8px 14px;
    color: #222;
    text-decoration: none;
    font-size: 14px;
}

.sdfm-submenu li a:hover {
    background: #f3f3f3;
}

/* =========================================================
   Filmstrip
   ========================================================= */

.sdfm-filmstrip {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.sdfm-filmstrip img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================================
   Mobile Navigation
   ========================================================= */

#primary-nav-button {
    display: none;
}

@media (max-width: 900px) {

    #primary-nav-button {
        display: inline-block;
        background: #3b6edb;
        color: #fff;
        border: none;
        padding: 8px 14px;
        border-radius: 4px;
        cursor: pointer;
    }

    .sdfm-menu {
        display: none;
        flex-direction: column;
        gap: 0;
        width: 100%;
        margin-top: 10px;
    }

    .sdfm-menu.active {
        display: flex;
    }

    .sdfm-menu > li > a,
    .sdfm-dropdown-toggle {
        padding: 10px 0;
    }
}

/* =========================================================
   Calendar Layout
   ========================================================= */

#calendar {
    max-width: 800px;
    margin: 0 auto;
}

/* Legend */

.calendar-legend {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 10px 0 15px 0;
    font-size: 13px;
    flex-wrap: wrap;
}

.calendar-legend .legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.calendar-legend .legend-colour {
    width: 12px;
    height: 12px;
    border-radius: 2px;
    border: 1px solid #555;
    display: inline-block;
}

/* =========================================================
   Calendar Event Detail Page
   ========================================================= */

.calendar-event-card {
    background: #fff;
    padding: 25px;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    margin-top: 20px;
}

.calendar-event-title {
    margin-top: 0;
    font-weight: 400;
}

.calendar-event-meta {
    display: block;
}

.calendar-event-date,
.calendar-event-category {
    font-size: 14px;
}

.category-badge {
    display: inline-block;
    padding: 4px 10px;
    color: #fff;
    border-radius: 3px;
    font-size: 13px;
}

.calendar-event-notes {
    margin-top: 15px;
    font-size: 14px;
    line-height: 1.6;
}

/* Calendar admin compact inputs */
.calendar-admin .form-control,
.calendar-admin input[type="datetime-local"].form-control {
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
  padding: 4px 8px !important;
  font-size: 13px !important;
  box-sizing: border-box !important;
}

.calendar-admin label {
  margin-bottom: 4px;
}

.calendar-admin .form-group {
  margin-bottom: 12px;
}

/* Make Calendarbadmin form compact */
.member-home .form-control.input-sm {
    height: 30px;
    padding: 4px 8px;
    font-size: 13px;
}

.member-home label {
    font-size: 13px;
    margin-bottom: 4px;
}

.member-home .form-group {
    margin-bottom: 12px;
}


/* =========================================================
   HEADER2DEV MENU SWITCHING
========================================================= */

/* ---------------------------------------------------------
   DEFAULT
   Standard menu visible
--------------------------------------------------------- */

.header2dev .menu-standard {
    display: block !important;
}

.header2dev .menu-xl {
    display: none !important;
}


/* ---------------------------------------------------------
   EXTRA LARGE (1400+)
--------------------------------------------------------- */

@media screen and (min-width: 1400px) {

    .header2dev .menu-standard {
        display: none !important;
    }

    .header2dev .menu-xl {
        display: block !important;
    }
}


/* =========================================================
   STANDARD MENU LAYOUT
========================================================= */

.header2dev .menu-standard ul.dropdown.menu,
.header2dev .menu-xl ul.dropdown.menu {
    display: flex !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
    align-items: center !important;
    gap: 12px !important;
}

.header2dev .menu-standard ul.dropdown.menu > li,
.header2dev .menu-xl ul.dropdown.menu > li {
    flex: 0 0 auto !important;
}

/* =========================================================
   MOBILE MENU
========================================================= */

@media screen and (max-width: 769px) {

    .header2dev .menu-standard ul.dropdown.menu {
        display: none !important;
        flex-direction: column !important;
        width: 100% !important;
        text-align: left !important;
        align-items: flex-start !important;
    }

    .header2dev .menu-standard ul.dropdown.menu.active {
        display: flex !important;
    }

    .header2dev #primary-nav-button {
        display: inline-block !important;
    }
}

/* =========================================================
   DROPDOWNS
========================================================= */

.header2dev ul.sub-menu li {
    display: block !important;
    width: 100% !important;
    float: none !important;
}


/* =========================================================
   MENU VISIBILITY RULES
========================================================= */

/* Hidden by default */

.header2dev .medium-only,
.header2dev .large-only {
    display: none !important;
}


/* ---------------------------------------------------------
   MEDIUM
   770–1199
   Competitions + Projects INSIDE dropdown
--------------------------------------------------------- */

@media screen and (min-width: 770px) and (max-width: 1199px) {

    .header2dev .medium-only {
        display: list-item !important;
    }
}


/* ---------------------------------------------------------
   LARGE
   1200–1399
   Competitions + Projects ON TOP MENU
--------------------------------------------------------- */

@media screen and (min-width: 1200px) and (max-width: 1399px) {

    .header2dev .large-only {
        display: list-item !important;
    }

    /* Explicitly hide medium dropdown items */

    .header2dev ul.sub-menu .medium-only {
        display: none !important;
    }
}


/* ---------------------------------------------------------
   XL
   1400+
   Uses separate XL menu
--------------------------------------------------------- */

@media screen and (min-width: 1400px) {

    .header2dev ul.sub-menu .medium-only,
    .header2dev .large-only {
        display: none !important;
    }
}

/* =========================================================
   MOBILE MENU
========================================================= */

@media screen and (max-width: 769px) {

    .header2dev .menu-standard ul.dropdown.menu {
        display: none !important;
        flex-direction: column !important;
        width: 100% !important;
        text-align: left !important;
        align-items: flex-start !important;
    }

    .header2dev .menu-standard ul.dropdown.menu.active {
        display: flex !important;
    }

    .header2dev #primary-nav-button {
        display: inline-block !important;
    }
}

/* =========================================================
   DROPDOWNS
========================================================= */

.header2dev ul.sub-menu li {
    display: block !important;
    width: 100% !important;
    float: none !important;
}


/* =========================================================
   MENU VISIBILITY RULES
========================================================= */

/* Hidden by default */

.header2dev .medium-only,
.header2dev .large-only {
    display: none !important;
}


/* ---------------------------------------------------------
   MEDIUM
   770–1199
   Competitions + Projects INSIDE dropdown
--------------------------------------------------------- */

@media screen and (min-width: 770px) and (max-width: 1199px) {

    .header2dev .medium-only {
        display: list-item !important;
    }
}


/* ---------------------------------------------------------
   LARGE
   1200–1399
   Competitions + Projects ON TOP MENU
--------------------------------------------------------- */

@media screen and (min-width: 1200px) and (max-width: 1399px) {

    .header2dev .large-only {
        display: list-item !important;
    }

    /* Explicitly hide medium dropdown items */

    .header2dev ul.sub-menu .medium-only {
        display: none !important;
    }
}


/* ---------------------------------------------------------
   XL
   1400+
   Uses separate XL menu
--------------------------------------------------------- */

@media screen and (min-width: 1400px) {

    .header2dev ul.sub-menu .medium-only,
    .header2dev .large-only {
        display: none !important;
    }
}

.mobile-info-menu {
    display: none !important;
}

@media screen and (max-width: 999px) {

    .mobile-info-menu {
        display: list-item !important;
    }

    .desktop-info-item {
        display: none !important;
    }
}

/* =========================================================
   MEMBER HEADER TOP GAP
========================================================= */

.header2dev #header {
    margin-top: 50px !important;
    }
    /* =========================================================
   MAKE MEMBER HEADER MATCH PUBLIC HEADER
========================================================= */

.header2dev {
    padding-top: 20px;
}

.header2dev #header {
    background: #fff;
}

.header2dev .filmstrip-container {
    margin-top: 0;
}


.page-banner {
    width: 100%;
    min-height: 20px;
    height: auto;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center top;
    position: relative;
}

.page-banner .banner-caption {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-banner img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================================
   PAGE BANNER
========================================================= */

.page-banner {
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.page-banner img {
    width: 100%;
    height: auto;
    display: block;
}

/* =========================================================
   HOMEPAGE CONTENT SPACING
========================================================= */

.page-banner + main .our-services {
    padding-top: 30px !important;
}

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 768px) {

    /* Hide large banner image on phones */
    .page-banner {
        display: none;
    }

    /* Reduce huge whitespace above content */
    .our-services {
        padding-top: 20px !important;
    }

    /* Reduce heading spacing */
    .our-services h1,
    .our-services h2 {
        margin-top: 0 !important;
        padding-top: 0 !important;
        font-size: 38px;
        line-height: 1.1;
    }
}

@media (max-width: 768px) {

    .page-banner + main .our-services {
        padding-top: 10px !important;
    }
}

/* =========================================================
   Floating menu
========================================================= */

#header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;

    z-index: 1000;

    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);

    border-bottom: 1px solid rgba(0,0,0,0.08);

    padding: 0;
    margin: 0;
}
body {
    padding-top: 80px;
}