/**
 * Altroz Technologies - Responsive Styles
 * Mobile-first approach for 320px - 1440px+
 * Breakpoints: Mobile (320-480), Tablet (481-1024), Desktop (1025+)
 */

/* ============================================
   Base: Responsive Images & Containers
   ============================================ */

img,
.img-responsive,
.img-fluid {
  max-width: 100%;
  height: auto;
}

.img-responsive,
.img-fluid {
  display: block;
}

.container {
  width: 100%;
  padding-left: 15px;
  padding-right: 15px;
  margin-left: auto;
  margin-right: auto;
}

/* Prevent horizontal scroll */
html,
body {
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

/* ============================================
   Social Sidebar (nav1) - Hide on mobile/tablet
   ============================================ */

@media (max-width: 1024px) {
  .nav1 {
    display: none !important;
  }
}

/* ============================================
   Typography - Mobile First
   ============================================ */

/* Mobile default (320px - 480px) */
h1, h1.page-title {
  font-size: 24px;
  line-height: 1.3;
}

h2, h2.section-title {
  font-size: 22px;
}

h3, h3.sub-title {
  font-size: 18px;
}

p, .section-description {
  font-size: 14px;
  line-height: 1.6;
}

/* Tablet (481px+) */
@media (min-width: 481px) {
  h1, h1.page-title {
    font-size: 28px;
  }
  h2, h2.section-title {
    font-size: 26px;
  }
  h3, h3.sub-title {
    font-size: 20px;
  }
  p, .section-description {
    font-size: 15px;
  }
}

/* Tablet large (768px+) */
@media (min-width: 768px) {
  h1, h1.page-title {
    font-size: 32px;
  }
  h2, h2.section-title {
    font-size: 30px;
  }
  h3, h3.sub-title {
    font-size: 22px;
  }
  p, .section-description {
    font-size: 16px;
  }
}

/* Desktop (1025px+) */
@media (min-width: 1025px) {
  h1, h1.page-title {
    font-size: 40px;
  }
  h2, h2.section-title {
    font-size: 32px;
  }
  h3, h3.sub-title {
    font-size: 22px;
  }
  .container {
    max-width: 1200px;
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* ============================================
   Navbar - Mobile & Tablet
   ============================================ */

@media (max-width: 768px) {
  .fh5co-nav-toggle {
    min-width: 48px;
    min-height: 48px;
    padding: 12px;
  }
  #fh5co-header .fluid-container {
    width: 100%;
  }
  #fh5co-header .navbar-default {
    padding-left: 0;
    padding-right: 0;
  }
  #fh5co-header .navbar-default .navbar-header {
    padding: 12px 15px;
  }
  #fh5co-header .navbar-logo {
    max-height: 80px;
  }
  #fh5co-header #navbar {
    padding: 15px;
    max-height: 70vh;
    overflow-y: auto;
  }
  #fh5co-header #navbar .navbar-right {
    flex-direction: column;
    width: 100%;
  }
  #fh5co-header #navbar li {
    width: 100%;
    text-align: left;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  }
  #fh5co-header #navbar li a {
    padding: 14px 10px !important;
    display: block;
    min-height: 48px;
  }
  #fh5co-header #navbar li.call-to-action {
    margin-left: 0;
    margin-top: 8px;
  }
  #fh5co-header #navbar li.call-to-action a {
    margin-top: 0;
    padding: 12px 16px;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  #fh5co-header .dropdown-menu {
    position: static !important;
    float: none !important;
    width: 100%;
    box-shadow: none !important;
    border: none !important;
    padding-left: 15px !important;
  }
  #fh5co-header .dropdown-menu li a {
    padding: 12px 10px !important;
    min-height: 44px;
  }
}

/* ============================================
   Hero Section
   ============================================ */

#fh5co-home {
  background-size: cover;
  background-position: center;
}

#fh5co-home,
#fh5co-home .text-wrap {
  min-height: 400px;
  height: auto;
}

@media (min-width: 481px) {
  #fh5co-home,
  #fh5co-home .text-wrap {
    min-height: 450px;
  }
}

@media (min-width: 768px) {
  #fh5co-home,
  #fh5co-home .text-wrap {
    min-height: 500px;
  }
}

@media (min-width: 1025px) {
  #fh5co-home,
  #fh5co-home .text-wrap {
    min-height: 600px;
  }
}

#fh5co-home .text-inner h1 {
  font-size: 22px;
  padding: 0 10px;
}

@media (min-width: 481px) {
  #fh5co-home .text-inner h1 {
    font-size: 26px;
  }
}

@media (min-width: 768px) {
  #fh5co-home .text-inner h1 {
    font-size: 34px;
  }
}

@media (min-width: 1025px) {
  #fh5co-home .text-inner h1 {
    font-size: 38px;
  }
}

/* ============================================
   Section Spacing
   ============================================ */

.section,
#fh5co-services,
#fh5co-testimony,
#fh5co-explore,
#fh5co-footer {
  padding: 40px 20px;
}

@media (min-width: 768px) {
  .section,
  #fh5co-services,
  #fh5co-testimony,
  #fh5co-explore,
  #fh5co-footer {
    padding: 60px 40px;
  }
}

@media (min-width: 1025px) {
  .section,
  #fh5co-services,
  #fh5co-testimony,
  #fh5co-explore,
  #fh5co-footer {
    padding: 80px 0;
  }
}

/* ============================================
   HRMS / Explore Section - Product Layout
   ============================================ */

@media (max-width: 991px) {
  .fh5co-explore .row,
  .fh5co-explore .product-block-row {
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
  }
  .fh5co-explore .row > [class*="col-"],
  .fh5co-explore .product-block-row > [class*="col-"] {
    width: 100% !important;
    max-width: 100% !important;
    flex: 0 0 100% !important;
  }
  .fh5co-explore .mt {
    margin-top: 0;
    margin-bottom: 0;
    padding-left: 0 !important;
    padding-right: 0;
  }
  .fh5co-explore .product-block-image {
    padding: 0 0 24px 0;
    order: 1;
  }
  .fh5co-explore .product-block-content {
    order: 2;
  }
  .fh5co-explore .product-block-inner {
    padding-left: 0;
    padding-right: 0;
  }
  .fh5co-explore-bg-color .row > [class*="col-"],
  .fh5co-explore-bg-color .product-block-row > [class*="col-"] {
    padding-right: 0 !important;
    padding-left: 0 !important;
  }
}

/* ============================================
   Testimony Section
   ============================================ */

#fh5co-testimony .wrap-testimony .testimony-slide blockquote {
  width: 100%;
  padding: 0 15px;
}

#fh5co-testimony .wrap-testimony .testimony-slide blockquote p {
  font-size: 16px;
}

@media (min-width: 768px) {
  #fh5co-testimony .wrap-testimony .testimony-slide blockquote {
    width: 72%;
  }
  #fh5co-testimony .wrap-testimony .testimony-slide blockquote p {
    font-size: 20px;
  }
}

/* ============================================
   Services Grid
   ============================================ */

@media (max-width: 767px) {
  .fh5co-services .row {
    margin-left: 0;
    margin-right: 0;
  }
  .fh5co-services .row > [class*="col-"] {
    width: 100%;
    padding-left: 0;
    padding-right: 0;
  }
  .fh5co-services .box-services {
    margin-bottom: 30px;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .fh5co-services .row > .col-md-4 {
    width: 50%;
    float: left;
  }
}

/* ============================================
   Pricing Cards (index page hidden section)
   ============================================ */

@media (max-width: 991px) {
  .fh5co-pricing .pricing > [class*="col-"] {
    width: 100% !important;
    max-width: 100% !important;
  }
}

/* ============================================
   Footer
   ============================================ */

@media (max-width: 1024px) {
  #fh5co-footer .row {
    display: flex;
    flex-wrap: wrap;
    margin-left: 0;
    margin-right: 0;
  }
  #fh5co-footer .row > .col-md-4 {
    flex: 1 1 100%;
    width: 100%;
    max-width: 100%;
    margin-bottom: 30px;
  }
}

@media (min-width: 768px) and (max-width: 1024px) {
  #fh5co-footer .row > .col-md-4 {
    flex: 1 1 calc(50% - 15px);
    width: calc(50% - 15px);
    max-width: calc(50% - 15px);
  }
}

@media (min-width: 1025px) {
  #fh5co-footer .row > .col-md-4 {
    margin-bottom: 0;
  }
}

@media (max-width: 767px) {
  #fh5co-footer .row {
    margin-left: 0;
    margin-right: 0;
  }
  #fh5co-footer .section-title {
    font-size: 20px;
  }
  #fh5co-footer .contact-info li {
    font-size: 14px;
    padding-left: 30px;
  }
}

/* ============================================
   Buttons & Inputs - Touch Friendly
   ============================================ */

button,
.btn,
input[type="submit"],
input[type="button"],
input[type="email"],
input[type="text"],
input[type="name"],
input[type="tel"],
select,
textarea {
  min-height: 48px;
  padding: 12px 16px;
}

@media (min-width: 768px) {
  button,
  .btn,
  input[type="submit"],
  input[type="button"] {
    min-height: auto;
    width: auto;
  }
}

#fh5co-footer .contact-form .form-group input,
#fh5co-footer .contact-form .form-group textarea {
  min-height: 48px;
}

#fh5co-footer .contact-form textarea {
  min-height: 120px;
}

/* ============================================
   Demo Modal - Responsive
   ============================================ */

.demo-modal-overlay {
  padding: 15px;
  align-items: flex-start;
  padding-top: 20px;
}

.demo-modal {
  max-height: 85vh;
}

.demo-modal-content {
  padding: 30px 20px 25px;
}

.demo-form-row {
  flex-direction: column;
  gap: 0;
  margin-bottom: 16px;
}

.demo-form-row .demo-form-group {
  flex: 1 1 100%;
}

@media (min-width: 600px) {
  .demo-form-row {
    flex-direction: row;
    gap: 20px;
  }
  .demo-modal-content {
    padding: 40px 35px 35px;
  }
}

/* ============================================
   Partner Section (Trusted / Partners page)
   ============================================ */

.partner-logo {
  display: block;
  width: 100%;
  float: none;
}

.fh5co-trusted .row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

/* ============================================
   Page-specific: Partners, Pricing, About, Referral
   ============================================ */

/* Partners hero */
@media (max-width: 768px) {
  .partners-hero {
    padding: 40px 20px 60px;
  }
  .partners-hero .hero-headline {
    font-size: 28px;
  }
  .partners-hero .hero-desc {
    font-size: 16px;
  }
  .partners-types .section-heading,
  .partners-why .section-heading {
    font-size: 26px;
  }
  .partners-form-card {
    padding: 24px;
  }
  .partners-form-card .form-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .partners-hero .hero-headline {
    font-size: 24px;
  }
}

/* Pricing page */
.pricing-table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -15px 40px;
  padding: 0 15px;
}

.pricing-comparison-table {
  min-width: 600px;
}

@media (max-width: 768px) {
  .pricing-card {
    margin-bottom: 20px;
  }
}

/* About page - already has some responsive, ensure consistency */
@media (max-width: 480px) {
  .about-purpose .purpose-block {
    padding: 32px 20px;
  }
  .about-purpose .purpose-heading {
    font-size: 24px;
  }
  .about-intro-inner {
    padding: 24px;
  }
  .about-cta h2 {
    font-size: 24px;
  }
  .about-cta-buttons {
    flex-direction: column;
  }
}

/* Referral page */
@media (max-width: 768px) {
  .referral-hero h1 {
    font-size: 28px;
  }
  .referral-ready-banner {
    padding: 32px 24px;
  }
  .referral-ready-banner h2 {
    font-size: 24px;
  }
  .referral-cta-bar {
    flex-direction: column;
    text-align: center;
  }
  .referral-cta-bar-floating {
    padding: 12px 16px;
  }
}

@media (max-width: 480px) {
  .referral-hero h1 {
    font-size: 22px;
  }
}

/* Careers page */
@media (max-width: 768px) {
  .job-item {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ============================================
   Fluid container mobile padding
   ============================================ */

@media (max-width: 767px) {
  .fluid-container {
    padding-left: 0;
    padding-right: 0;
  }
}

/* ============================================
   Feature List - HRMS / Email
   ============================================ */

.feature-list li {
  font-size: 14px;
}

@media (min-width: 768px) {
  .feature-list li {
    font-size: 15px;
  }
}

/* ============================================
   Section Header
   ============================================ */

.section-header {
  margin-bottom: 30px;
}

.section-header .section-title {
  margin-bottom: 12px;
}

@media (min-width: 768px) {
  .section-header {
    margin-bottom: 50px;
  }
}

/* ============================================
   col-md-offset-2 override for mobile
   ============================================ */

@media (max-width: 767px) {
  .col-md-offset-2 {
    margin-left: 0;
  }
}
