/* ================================================
   SERVICES PAGE — PREMIUM DESIGN 2.0
   ================================================ */

:root {
    --primary-blue: #1a3c75;
    --accent-blue: #2563eb;
    --light-blue: #38bdf8;
    --dark-bg: #0f172a;
    --text-main: #334155;
    --text-muted: #64748b;
    --card-shadow: 0 15px 35px rgba(37, 99, 235, 0.1);
    --dark-modal-border: rgba(255, 255, 255, 0.1);
}

/* --- HERO SECTION --- */
.services-hero {
    height: 70vh;
    min-height: 550px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    color: #fff;
    margin-top: 100px; /* SPACE FOR FIXED HEADER */
}

.services-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(100deg, rgba(15, 23, 42, 0.95) 0%, rgba(37, 99, 235, 0.4) 60%, rgba(0,0,0,0.1) 100%);
    z-index: 1;
}

.services-hero .auto-container {
    position: relative;
    z-index: 2;
}

.hero-tagline {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--light-blue);
    margin-bottom: 20px;
    display: block;
}

.services-hero h1 {
    font-size: 64px;
    font-weight: 900;
    margin-bottom: 15px;
    letter-spacing: -2px;
    line-height: 1.1;
    text-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

.services-hero .main-title {
    font-size: 24px;
    font-weight: 500;
    max-width: 800px;
    line-height: 1.4;
    margin-bottom: 20px;
    color: #e2e8f0;
    text-transform: none;
}

.services-hero .description {
    font-size: 18px;
    max-width: 700px;
    line-height: 1.65;
    color: #94a3b8;
    margin-bottom: 45px;
}

.hero-features {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    padding: 14px 22px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-item:hover {
    background: rgba(56,189,248,0.2);
    border-color: var(--light-blue);
    transform: translateY(-5px);
}

.feature-item i {
    font-size: 24px;
    color: var(--light-blue);
}

.feature-item span {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

/* --- WHAT WE DO SECTION --- */
.what-we-do {
    padding: 100px 0;
    background: #f8fafc;
}

.section-header {
    text-align: center;
    margin-bottom: 70px;
}

.section-header h2 {
    font-size: 42px;
    font-weight: 900;
    color: #0f172a;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    padding-bottom: 25px;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 70px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-blue), var(--light-blue));
    border-radius: 4px;
}

/* --- SERVICE GRID --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.service-card {
    background: #ffffff;
    border-radius: 20px;
    border: 1px solid rgba(226, 232, 240, 0.8);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-blue), var(--light-blue));
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 30px 60px -12px rgba(37, 99, 235, 0.15);
    border-color: rgba(147, 197, 253, 0.5);
}

.service-card:hover::after {
    width: 100%;
}

.card-num {
    position: absolute;
    top: 175px; 
    right: 25px;
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-blue));
    color: #fff;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 800;
    z-index: 5;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.3);
    border: 3px solid #fff;
    transition: transform 0.4s ease;
}

.service-card:hover .card-num {
    transform: scale(1.1) rotate(10deg);
}

.card-image {
    width: 100%;
    height: 200px;
    position: relative;
    overflow: hidden;
}

.card-image::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.7) 0%, transparent 50%);
    z-index: 2;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover .card-image::before {
    opacity: 1;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    position: relative;
    z-index: 1;
}

.service-card:hover .card-image img {
    transform: scale(1.1);
}

.card-content {
    padding: 30px 25px 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    font-size: 21px;
    font-weight: 800;
    color: var(--dark-bg);
    margin-bottom: 15px;
    line-height: 1.3;
    transition: color 0.4s ease;
}

.service-card:hover .card-content h3 {
    color: var(--accent-blue);
}

.card-content p {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 25px;
    flex-grow: 1;
}

.explore-link {
    font-size: 14px;
    font-weight: 700;
    color: var(--accent-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.4s;
    text-decoration: none !important;
    padding: 10px 20px;
    background: rgba(37,99,235,0.06);
    border-radius: 50px;
    align-self: flex-start;
}

.explore-link i {
    transition: transform 0.4s;
}

.explore-link:hover {
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-blue));
    color: #ffffff !important;
    box-shadow: 0 8px 15px rgba(37, 99, 235, 0.2);
}

.explore-link:hover i {
    transform: translateX(4px);
}

/* --- PREMIUM MODAL --- */
#myModal .modal-dialog {
    max-width: 650px;
    margin: 80px auto;
}

#myModal .modal-content {
    border-radius: 24px;
    border: none;
    box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    padding: 0;
    background-color: #ffffff !important; /* Force solid white */
}

#myModal .modal-header {
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-blue));
    color: #fff;
    padding: 25px 30px;
    border-bottom: none;
    position: relative;
    display: block;
}

#myModal .modal-header .modal-title {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

#myModal .modal-header .close {
    position: absolute;
    top: 22px;
    right: 25px;
    background: rgba(255,255,255,0.15);
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    font-size: 18px;
    border: none;
    transition: all 0.3s;
}

#myModal .modal-header .close:hover {
    background: #ef4444;
    transform: rotate(90deg);
}

#myModal .modal-body {
    padding: 30px;
    background: #ffffff;
}

#myModal .modal-body .form-group {
    margin-bottom: 20px;
    position: relative;
}

/* Modal Icons Mapping */
#myModal .modal-body .input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-blue);
    font-size: 16px;
    z-index: 10;
}

#myModal .modal-body .form-control {
    height: 52px;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 10px 15px 10px 45px;
    font-size: 15px;
    color: var(--dark-bg);
    transition: all 0.3s;
    background: #fff;
    box-shadow: none !important;
}

#myModal .modal-body .form-control:focus {
    border-color: var(--accent-blue);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1) !important;
}

#myModal .modal-body textarea.form-control {
    height: 160px;
    padding-top: 15px;
    resize: none;
}

#myModal .modal-body .message-icon {
    top: 20px;
    transform: none;
}

#myModal .modal-footer {
    padding: 0 30px 30px;
    border-top: none;
    text-align: center;
    background: #ffffff;
    display: block;
}

#myModal .modal-footer .theme-btn {
    background: linear-gradient(135deg, var(--primary-blue), var(--accent-blue)) !important;
    color: #fff !important;
    width: 60%;
    height: 54px;
    border-radius: 12px !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.4s;
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.4) !important;
}

#myModal .modal-footer .theme-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px -5px rgba(37, 99, 235, 0.5) !important;
}

/* Responsive Grid */
@media (max-width: 1200px) {
    .services-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 991px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .services-hero h1 { font-size: 48px; }
    .services-hero { margin-top: 80px; }
}

@media (max-width: 600px) {
    .services-grid { grid-template-columns: 1fr; }
    .services-hero { height: auto; padding: 120px 0 60px; }
    .services-hero h1 { font-size: 36px; }
    .modal-footer .theme-btn { width: 100%; }
}

/* --- SERVICE DETAIL SECTION (Matches Technical Documentation screenshot) --- */
.service-detail-wrapper {
    padding: 80px 0;
    background: #ffffff;
    margin-top: 100px;
}

.service-detail-section {
    margin-bottom: 80px;
}

.service-detail-section:last-child {
    margin-bottom: 0;
}

/* Alternate backgrounds */
.service-detail-section.bg-light {
    background: #f8fafc;
    padding: 60px 0;
}

.detail-header {
    text-align: center;
    max-width: 1000px;
    margin: 0 auto 50px;
}

.detail-header h2 {
    font-size: 32px;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 15px;
    text-transform: none;
}

.detail-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: #94a3b8; /* Subtle underline */
}

.detail-header p {
    font-size: 16px;
    line-height: 1.8;
    color: #475569;
}

.detail-content-grid {
    display: flex;
    align-items: flex-start;
    gap: 60px;
}

.detail-image-box {
    flex: 1;
}

.detail-image-box img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.detail-info-box {
    flex: 1;
}

.detail-info-box h3 {
    font-size: 24px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 20px;
}

.detail-list {
    list-style: none;
    padding: 0;
    margin: 0 0 35px;
}

.detail-list li {
    padding: 12px 0;
    font-size: 15px;
    color: #64748b;
    border-bottom: 1px solid #f1f5f9;
}

.detail-list li:last-child {
    border-bottom: none;
}

.btn-enquire-now {
    display: inline-block;
    background: #2176a7;
    color: #fff !important;
    padding: 14px 45px;
    border-radius: 6px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 15px;
    letter-spacing: 0.5px;
    transition: all 0.3s;
    text-decoration: none !important;
}

.btn-enquire-now:hover {
    background: #1a5c82;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(33, 118, 167, 0.3);
}

@media (max-width: 991px) {
    .detail-content-grid {
        flex-direction: column;
        gap: 40px;
    }
}