/* Global Styles */
html {
    font-size: calc(14px + 0.5vw); /* Fluid base font size */
    box-sizing: border-box;
}

*, *:before, *:after {
    box-sizing: inherit;
}

body {
    overflow-x: hidden;
    width: 100%;
    margin: 0; 
    padding: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #f7f7f7;
    color: #222;
    touch-action: manipulation; /* Better mobile touch handling */
}
 

header {
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    display: flex;
    flex-wrap: wrap; /* Allows items to wrap on small screens */
    align-items: center;
    justify-content: space-between;
    padding: 0 2%; /* Percentage-based padding */
    height: auto; /* Changed from fixed height */
    min-height: 56px;
    position: fixed;
    top: 0; 
    left: 0;
    z-index: 1000;
}

header h2 {
    font-size: clamp(1rem, 1.0em, 1.3rem); 
    font-weight: 600;
    letter-spacing: 1px;
    margin: 0 20px 0 0; /* Reduced margin */
    line-height: 1.3;
}

nav ul {
    display: flex;
    flex-wrap: wrap; /* Allows menu items to wrap */
    gap: 15px; /* Reduced gap */
    list-style: none;
    margin: 0;
    padding: 10px 0; /* Added vertical padding */
    align-items: center;
}

nav ul li {
    display: flex;
    align-items: center;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    font-size: 0.97em;
    font-weight: 400;
    padding: 0 5px;
    transition: color 0.2s;
}

nav ul li a.active,
nav ul li a:hover {
    color: #1ba6ab;
    font-weight: 600;
}

.button {
    display: flex;

}

.button a {
    background: #1ba6ab;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 5px 10px;
    font-size: 0.97em;
    font-weight: 500;
    text-decoration: none;
    margin: 15px 5px;
    transition: background 0.2s;
}

.button a.login {
    background: #009ca6;
}

.button a.book {
    background: #1ba6ab;
}

.button a:hover {
    background: #007c85;
}
.main-content {
  margin: 0 auto;
  max-width: 2000px;
  width: 100%;
  transition: margin-left 0.3s ease;
  overflow-y: auto
}

/* Welcome Section */
#welcome {
    width: 100%;
    min-height: 100vh;
    background: url('../../static/images/bg landing page.jpeg') left/cover no-repeat;
    display: flex;
    flex-direction: row; /* Changed to row layout */
    align-items: center; /* Center vertically */
    justify-content: flex-start; /* Align content to start (left) */
    position: relative;
    padding: 80px 5% 10px;
    box-sizing: border-box;
    overflow: hidden; /* Prevent any overflow from positioned elements */
}

#welcome::before {
    content: "";
    background-color: #03030386;
    position: absolute;
    inset: 0;
    object-fit: cover;
    z-index: 1;
    pointer-events: none;
}

.welcome-header {
    position: relative;
    z-index: 2;
    align-self: flex-start; /* aligns it to the left of the flex container */
    color: #ffffff;
}

#welcome h2 {
    font-size: 1.2em;
    font-weight: 700;    
    margin-bottom: 20px;
    margin-left: 50px;
    letter-spacing: 2px;
    text-align: center;
    align-items: flex-end;
}

.ai-character-container {
    width: 100%; /* Adjust width as needed */
    max-width: 850px;
    max-height: 850px;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative; /* Changed from absolute to relative */
    top: 20vh;
    margin-bottom: 0;
    margin-right: 2%; /* Space between image and chat */
    z-index: 2;
}
.ai-character-container img {
    width: 100%;
    height: auto;
    max-height: 850px;
    object-fit: contain;
}

/* chat container*/
.chat-container {
    max-height: 100%;  /* Set a maximum height */
    min-height: 200px;  /* Set a minimum height */
    width: 700px;
    overflow-y: auto;   /* Change to auto for better scrollbar behavior */
    border: none;
    border-radius: 5px;
    padding: 10px;
    margin-bottom: 20px;
    text-align: left;
    background-color: #20202056;
    display: flex;
    flex-direction: column;
}
.user-message {
    background-color: none !important;
    padding: 8px 12px;
    border-radius: 18px;
    margin-bottom: 8px;
    max-width: 100%;
    margin-left: auto;
}
.bot-message {
    background-color:none !important;
    padding: 8px 12px;
    border-radius: 18px;
    margin-bottom: 8px;
    max-width: 100%;
}
.message-time {
    font-size: 0.7em;
    color: #666;
    margin-top: 4px;
}

.chat-input-row {
    position: relative;
    z-index: 3;
    width: 45%;
    max-width: 700px;
    margin-top: 20%;
    margin-left: auto; /* Push to right side */
    margin-right: 8%;
    margin-bottom: 5vh; /* Distance from bottom */
}


.chat-input-container {
    display: flex;
    width: 100%;
    background: rgba(255, 255, 255, 0.1); /* Added background for better visibility */
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2); /* Optional border */
}

#welcome .input-group {
    display: flex;
    align-items: center;
    gap: 0; /* Remove spacing if needed */
}

#welcome .input-group input {
    height: 60px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border: none;
    outline: none;
    color: #fff;

}

#welcome input::placeholder {
    color: #d1d1d1c9; 
    opacity: 2;  
    text-align: center;
}

#welcome .input-group #send-btn {
    height: 70px;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    background-color: #007c85;
    border-radius: 0 20px 20px 0;
}

#welcome .mic-button {
    height: 70px;
    width: 49px; /* Fixed width */
    margin-left: -1px; /* Avoid double borders */
    color: #ffffffce;
    background-color: #007c85;
    border: none;
}

/* toggleSpeech */
#toggleSpeech {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-left: auto;
  padding: 8px 15px;
  margin-top: 15px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, #4cafef, #007c85);
  border: none;
  border-radius: 15px;
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px #007c854f;
}

/* Hover / active feedback */
#toggleSpeech:hover {
  background: linear-gradient(135deg, #66cfff, #3399ff);
  box-shadow: 0 6px 16px #007c85;
  transform: translateY(-2px);
}

#toggleSpeech:active {
  transform: scale(0.95);
  box-shadow: 0 2px 8px #007c85;
}

/* Subtle animation when state changes (text swap feels smoother) */
#toggleSpeech {
  transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease, color 0.2s ease;
}


/* Branch Section - Enhanced with Bootstrap */
#branch {
    width: 100%;
    min-height: 100vh;
    background: url('../images/bg\ in\ branch.jpg') center/cover no-repeat fixed;
    position: relative;
    padding: 80px 0;
}
 
#branch::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(223, 236, 238, 0.85);
    z-index: 0;
}

.services_container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Header Styles */
.branch-header h2 {
    color: #00898E !important;
    font-size: 4rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 0;
}

.branch-header p {
    color: #444;
    font-size: 1.2rem;
    margin-bottom: 0;
    width: 100%;
}

/* Button List Styles */
.branch-list {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.branch-btn {
    background: #00898E !important;
    border: none;
    border-radius: 6px 0 0 6px !important;
    padding: 16px 20px;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    transition: all 0.3s ease;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.branch-btn:hover, 
.branch-btn.active {
    background: #00898ee7 !important;
    transform: translateX(5px);
    box-shadow: 3px 3px 8px rgba(0, 0, 0, 0.15);
}

.branch-btn::after {
    content: '';
    position: absolute;
    top: 0;
    right: -10px;
    width: 0;
    height: 0;
    border-top: 30px solid transparent;
    border-bottom: 30px solid transparent;
    border-right: 10px solid white;
    z-index: 2;
    transition: all 0.3s ease;
}

.branch-btn.active::after {
    right: -5px;
}

/* Card Styles */
.branch-details-card {
    border: none !important;
    border-radius: 12px !important;
    overflow: hidden;
    transition: all 0.3s ease;
    height: 100%;
    width: 100%;
    max-width:990px;
    min-height: 580px;
}

.branch-details-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
}

.branch-img-container {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    height: 450px;
    width: 350px;
    padding-bottom: 75%; /* 4:3 aspect ratio (adjust as needed) */
    background-color: #f5f5f5; /* Fallback color */
}

.branch-img {
  width: 100%;
  height: 100%;
  position: absolute;
    top: 0;
    left: 0;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  display: block;
  margin-top: 20px;
}

.branch-details-card:hover .branch-img {
    transform: scale(1.03);
}

.branch-info {
    padding: 0 1rem;
    margin-left: 55px;
}

.branch-info p {
    margin-bottom: 1.2rem;
    color: #030303;
    line-height: 1.6;
}

.branch-info strong {
    color: #242424 !important;
    font-weight: 600;
}

.view-more-btn {
    background: #00898ee8 !important;
    border: none;
    padding: 10px 25px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    align-self: flex-end;
    margin-top: auto;
}

.view-more-btn:hover {
    background: #007a82;
    transform: translateY(-2px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
}

/* SERVICE LIST heading style */
.branch-info:last-child h4 {
    color: #009ca6;
    font-size: 1.5em;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: 1px;
    background: none;
    padding: 0;
    display: inline-block;
}

/* Service List Bullets */
.branch-info ul {
    list-style: none;
    padding-left: 1.5rem !important; 
    margin-left: 0 !important;
}

.branch-info ul li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #00898E;
    font-weight: 700;
    font-size: 1.5rem;
}

.branch-info ul li {
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
    color: #555;
    position: relative;
    padding-left: 1.5rem;
}

/* Services Section */
#services {
    width: 100%;
    height: auto !important;
    background: #fff;
    padding: 48px 0 56px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.services-header {
    text-align: center; 
    margin-bottom: 24px;
}

.services-header h2 {
    color: #009ca6;
    font-size: 2.3em;
    font-weight: 700;
    margin: 0;
    letter-spacing: 2px;
}

.services-header p {
    color: #222;
    font-size: 1.1em;
    margin: 8px 0 0 0;
}

.services-cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin: 20px 5%; /* Responsive margins */
}

.service-card {
    width: 100%; /* Full width on mobile */
    max-width: 350px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.267);
    padding: 0 0 24px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s;
}

.service-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.13);
}

.service-img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 16px 16px 0 0;
}

.service-icon  i{
    width: 54px;
    height: 54px;
    background: #b8aea2; 
    color: #12726fe8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: -27px;
    margin-bottom: 8px;
    box-shadow: 0 5px 15px #fff;
}

.service-card h3 {
    font-size: 1.15em;
    font-weight: 700;
    color: #222;
    margin: 8px 0 8px 0;
    text-align: center;
}

.service-card p {
    font-size: 0.98em;
    color: #444;
    text-align: center;
    margin: 0 18px;
}

/* Selected Services Container */
.selected-services-container {
    width: 100%;
    padding: 20px 0;
}

.selected-services-cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin: 0 5%; /* Match your existing services-cards margins */
}

/* Ensures all cards (static and dynamic) have identical sizing */
.service-card, 
.selected-service-card .service-card {
    width: 100%;
    max-width: 350px;
    min-height: 470px; /* Fixed height */
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.267);
    padding: 0 0 24px 0;
    display: flex;
    flex-direction: column;
    grid-template-columns: repeat(4, 1fr); /* 4 equal columns */
    grid-template-rows: repeat(2, auto);
    align-items: center;
    transition: box-shadow 0.2s;
    position: relative; /* For absolute positioning of remove button */
}

/* Content area sizing */
.service-card-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 15px;
    width: 100%;
}

/* Footer */
footer {
    background: #009ca6;
    color: #fff;
    padding: 32px 0 24px 0;
    margin-top: 0; 
}

.footer-container {
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    max-width: 1200px;
    margin: 0 auto;
    gap: 60px;
    flex-wrap: wrap;
}

.footer-column {
    flex: 1 1 180px;
    min-width: 180px;
    margin-right: 24px;
}

.footer-column h3,
.footer-column h4 {
    font-size: 1.1em;
    font-weight: 700;
    margin-bottom: 10px;
    margin-top: 0;
}

.footer-column p {
    font-size: 0.95em;
    color: #e0e0e0;
    margin-bottom: 16px;
    margin-top: 0;
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-column ul li {
    margin-bottom: 6px;
}

.footer-column ul li a {
    color: #fff;
    text-decoration: none;
    font-size: 0.97em;
    transition: text-decoration 0.2s;
}

.footer-column ul li a:hover {
    text-decoration: underline;
}

.footer-social {
    margin-top: 10px;
}

.footer-social a {
    color: #fff;
    font-size: 1.2em;
    margin-right: 12px;
    transition: color 0.2s;
    display: inline-block;
}

.footer-social a:hover {
    color: #e0e0e0;
}