/**
 * CUSTOM HEADER MODIFICATIONS FOR ADULT SWINGERS COMMUNITY
 * File: /oc-content/themes/zeta/css/custom-header.css
 * Purpose: Increase header size for larger logos on desktop
 * Responsive: Maintains mobile optimization
 */

/* ==========================================================================
   DESKTOP HEADER MODIFICATIONS
   ========================================================================== */

/* Increase header height from 48px to 70px on desktop */
header {
  height: 70px !important;
}

/* Adjust body padding to match new header height */
body {
  padding-top: 70px !important;
}

/* Remove top padding from the main content area ONLY on the homepage to fix the gap */
body#home .content {
    padding-top: 0 !important;
}


/* Adjust for search and item pages (header + header-search) */
body#search, 
body#item {
  padding-top: 126px !important; /* 70px + 56px */
}

/* Increase logo image height for larger logos */
header .logo img {
  min-height: 50px !important;
  height: 50px !important;
}

/* Adjust header search positioning */
#header-search {
  top: 71px !important; /* header height + 1px */
}

/* Adjust flash message positioning */
#flashbox .wrap {
  top: 86px !important; /* 70px header + 16px spacing */
}

/* ==========================================================================
   RESPONSIVE OVERRIDES - MOBILE DEVICES
   ========================================================================== */

@media screen and (max-width: 767px) {
  /* Remove the search bar from the header on mobile */
  header .csearch-init {
    display: none !important;
  }
  
  /* Style the mobile login/register buttons in the header */
  .menu-links {
    display: flex;
    align-items: center;
  }
  .mobile-auth-links {
    display: flex;
    align-items: center;
    margin-right: 6px; /* Space between buttons and icons */
  }
  .mobile-auth-links .btn {
      padding: 4px 10px !important;
      font-size: 14px !important;
      font-weight: 600 !important;
      height: 32px !important;
      margin-left: 6px !important;
  }

  /* Hide Login/Register from the slide-out menu */
  #side-menu .section a.login,
  #side-menu .section a.register {
      display: none !important;
  }

  /* Reset to original mobile sizing */
  header {
    height: 60px !important;
  }
  
  header .logo img {
    min-height: 34px !important;
    height: 34px !important;
  }
  
  body {
    padding-top: 60px !important;
    padding-bottom: 48px;
  }
  
  body#search, 
  body#item {
    padding-top: 60px !important;
  }
  
  #flashbox .wrap {
    top: 72px !important;
  }
  
  /* Keep mobile square logo sizing */
  header .logo.square img {
    height: 36px !important;
    width: auto;
    max-width: 40px;
  }
}

/* ==========================================================================
   ADMIN BAR COMPATIBILITY
   ========================================================================== */

@media screen and (max-width: 767px) {
  .osc-has-admin-header header, 
  .osc-has-admin-header #header-search {
    margin-top: 46px; /* Mobile admin bar */
  }
}

@media screen and (min-width: 768px) {
  .osc-has-admin-header header, 
  .osc-has-admin-header #header-search {
    margin-top: 34px; /* Desktop admin bar */
  }
}

/* ==========================================================================
   DARK MODE COMPATIBILITY
   ========================================================================== */

html[mode="dark"] header {
  background-color: #1a1d1e;
  box-shadow: 0 1px 0 0 #393939;
}

html[mode="dark"] #header-search {
  background: var(--mb-color14);
  box-shadow: 0 1px 0 0 var(--mb-color12);
}

/**
 * ENHANCED VIDEO BLOCK STYLING
 * Add to /oc-content/themes/zara/css/custom-header.css
 */

/* ==========================================================================
   VIDEO BLOCK MAIN CONTAINER
   ========================================================================== */

/* Force video block to appear at the top of the main content area */
body#home > .content > #video-block {
    order: 1 !important;
}

#video-block {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  background-color: #000; /* Fallback color */
}

#video-block .video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* ==========================================================================
   VIDEO BLOCK ENHANCEMENTS
   ========================================================================== */

/* Ensure video covers full container and maintains aspect ratio */
#video-block .video video#video-play {
  z-index: 1;
  position: absolute; 
  top: 50%; 
  left: 50%; 
  min-width: 100%; 
  min-height: 100%; 
  width: auto; 
  height: auto; 
  transform: translateX(-50%) translateY(-50%); 
  background: url('../video/poster.jpg') no-repeat center center; 
  background-size: cover; 
  transition: 1s opacity;
  object-fit: cover; /* Better video scaling */
}

/* Enhanced video overlay for better text readability */
#video-block .video .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  background: rgba(0, 0, 0, 0.4);
  background: linear-gradient(
    135deg, 
    rgba(0, 0, 0, 0.3) 0%, 
    rgba(0, 0, 0, 0.5) 50%, 
    rgba(0, 0, 0, 0.3) 100%
  );
}

/* ==========================================================================
   SEARCH OVER VIDEO STYLES
   ========================================================================== */

/* Hide the original search block now that it's moved */
body#home #home-search-box {
    display: none !important;
}

/* Style for search content placed over the video */
#video-block #video-search-content {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    align-items: flex-start !important;
    justify-content: center !important;
    z-index: 3 !important;
    padding: 40px 15px 0 !important;
}

/* Remove background and shadows from the original search box when it's over the video */
#video-block #main-search {
    background-image: none !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 800px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

#video-block #main-search .box {
    width: 100% !important;
}

#video-block #main-search h1 {
    text-shadow: 0 2px 4px rgba(0,0,0,0.7) !important;
    text-align: center !important;
}

/* Hide the search tabs */
#video-block #main-search .tabs {
    display: none !important;
}

/* Visually hide unwanted search fields but keep them for the form submission */
#video-block #main-search .input-box.location,
#video-block #main-search .input-box.simple-radius,
#video-block #main-search .input-box.simple-cat {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

/* Adjust the search input container now that tabs are hidden */
#video-block #main-search .tab-data {
    border-radius: 5px !important;
}

/* Make search form fields white */
#video-block #main-search .tab-data,
#video-block #main-search .tab-data .input-box input, 
#video-block #main-search .tab-data .input-box .text {
    background-color: #ffffff !important;
    color: #333333 !important;
}

#video-block #main-search .tab-data .input-box {
    border-color: #dddddd !important;
}

/* Ensure the main search input has the correct border radius now that other fields are hidden */
#video-block #main-search .tab-data .input-box.pattern input {
    border-radius: 5px 0 0 5px !important;
}

/* ==========================================================================
   CATEGORY BLOCK STYLES
   ========================================================================== */

/* Force categories into a single row on desktop */
#home-cat {
    grid-template-columns: repeat(3, 1fr) !important;
    grid-auto-flow: row !important;
    justify-content: center !important;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

/* ==========================================================================
   RESPONSIVE VIDEO ADJUSTMENTS
   ========================================================================== */

@media screen and (max-width: 767px) {
  /* Set video height on mobile */
  #video-block {
    height: 420px !important;
  }
  
  /* Move "Browse Categories" below the video on mobile */
  body#home > .content > section.home-cat {
      order: 2 !important;
  }

  /* Force categories into a single row on mobile */
  #home-cat {
      grid-template-columns: repeat(3, 1fr) !important;
      grid-auto-flow: row !important;
      grid-template-rows: auto !important;
      overflow-x: initial !important;
      max-width: 100% !important;
  }

  /* Adjust search title font size on mobile */
  #video-block #main-search h1 {
      font-size: 24px !important;
      margin-bottom: 15px !important;
  }
    
  /* Stack search inputs vertically on mobile */
  #video-block #main-search .tab-data .inbox {
      flex-direction: column !important;
      height: auto !important;
  }
  
  #video-block #main-search .tab-data .input-box {
      width: 100% !important;
      border-right: none !important;
      border-bottom: 1px solid #e0e0e0 !important;
  }

  #video-block #main-search .tab-data .input-box:last-of-type {
      border-bottom: none !important;
  }

  #video-block #main-search .tab-data .btns {
      padding: 8px 5px !important;
  }
  
  #video-block #main-search .tab-data .btns .btn {
      width: 100% !important;
      height: 40px !important;
      text-align: center !important;
      justify-content: center !important;
  }
  
  /* Adjust video overlay opacity on mobile */
  #video-block .video .overlay {
    background: rgba(0, 0, 0, 0.5) !important;
  }
}
/*
 * ==========================================================================
 * BROWSE CATEGORIES BLOCK - CUSTOM STYLES (v8 - Final)
 * ==========================================================================
 */

/* Hide the "Search in all categories" button */
.home-link-all-wrap {
    display: none !important;
}

/* Main grid container with adjusted gap */
#home-cat {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    grid-gap: 24px !important;
    max-width: 960px !important;
    margin: 0 auto !important;
    padding: 10px !important;
}

/* Category link item */
#home-cat a {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    min-width: 140px;
    padding: 20px 10px !important;
    border-radius: 12px !important;
    border-bottom: 3px solid transparent !important;
    background-color: transparent !important;
    transition: background-color 0.2s ease, border-color 0.2s ease !important;
}

/* Hover state */
#home-cat a:hover,
#home-cat a:focus {
    background-color: #2a2a2a !important;
    border-bottom-color: var(--mb-color-primary, #ff2636) !important;
}

/* Disable old scaling animation on hover */
#home-cat a:hover > div {
    transform: none !important;
}

/* Add a purple glow to the icon on hover */
#home-cat a:hover > div img,
#home-cat a:hover > div svg {
    filter: drop-shadow(0 0 3px #A020F0) drop-shadow(0 0 5px #A020F0);
    transition: filter 0.2s ease-in-out;
}

/*
 * DESKTOP STYLES (>= 768px)
 * --------------------------------------------------------------------------
 */
@media screen and (min-width: 768px) {
    #home-cat a {
       padding: 15px 10px !important; /* UPDATED: Reduced vertical padding */
    }
    
    /* Icon container */
    #home-cat a > div {
        width: 85px !important; /* UPDATED: Reduced icon container size */
        height: 85px !important;
        border-radius: 15px !important;
        overflow: hidden !important;
        margin-bottom: 10px !important;
    }

    /* Icon image */
    #home-cat a > div img,
    #home-cat a > div svg {
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        max-height: none !important;
    }
    
    /* Font Awesome icon (if used) */
    #home-cat a > div i {
        font-size: 44px !important; /* UPDATED: Resized to match container */
        line-height: 85px !important;
    }

    /* Text below the icon */
    #home-cat a > h3 {
        width: 100%;
        text-align: center;
        height: auto !important;
        margin-top: 5px !important;
    }
    
    #home-cat a > h3 span {
        font-size: 18px !important;
        white-space: nowrap !important;
    }
}

/*
 * MOBILE STYLES (< 768px)
 * --------------------------------------------------------------------------
 */
@media screen and (max-width: 767px) {
    #home-cat {
        grid-gap: 5px !important;
        padding: 10px 15px !important;
    }

    #home-cat a {
      padding: 5px !important;
      min-width: 0;
    }

    #home-cat a > div {
        width: 60px !important;
        height: 60px !important;
        border-radius: 8px !important;
        overflow: hidden !important;
    }

    #home-cat a > div img,
    #home-cat a > div svg {
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        max-height: none !important;
    }
    
    #home-cat a > div i {
      font-size: 26px !important;
      line-height: 60px !important;
    }

    #home-cat a > h3 span {
        font-size: 11px !important;
        line-height: 1.2 !important;
        white-space: normal !important;
    }
}

/* Hide the 'Hello' welcome and action buttons block on the homepage */
section.home-action {
    display: none !important;
}

/*
 * ==========================================================================
 * HOMEPAGE WELCOME MESSAGE
 * ==========================================================================
 */

/* This wrapper will hold the combined welcome/search box */
#video-search-content .video-content-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 800px;
}

/* Styling for the new combined welcome message and search box */
.welcome-message-box {
    background-color: rgba(56, 16, 112, 0.7);
    color: #ffffff;
    padding: 20px 20px 40px;
    border-radius: 12px;
    width: 100%;
    max-width: 800px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Style the "Find someone sexy now!!" headline */
.welcome-message-box #main-search h1 {
    color: #00FFFF !important;
}

.welcome-message-box p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
}

.welcome-message-box p:not(:last-child) {
    margin-bottom: 10px;
}

/* Add more space between the welcome text and the search bar */
.welcome-message-box p:last-of-type {
    margin-bottom: 40px;
}


.welcome-message-box p strong {
    font-size: 22px;
    font-weight: 700;
}

/* On mobile, reduce padding and font sizes */
@media screen and (max-width: 767px) {
    .welcome-message-box {
        padding: 15px;
    }

    .welcome-message-box p {
        font-size: 13px;
    }

    .welcome-message-box p strong {
        font-size: 16px;
        line-height: 1.2;
    }

    /* Hide the "Welcome to" text on mobile */
    .welcome-message-box p strong .welcome-prefix {
        display: none;
    }
    
    /* Fix for search input corner radius on mobile */
    #video-block #main-search .tab-data .inbox {
        border-radius: 5px;
        overflow: hidden;
    }
    
    /* Change search box background to light purple on mobile */
    #video-block #main-search .tab-data {
        background-color: #E6E6FA !important; /* Light Purple (Lavender) */
    }
}