/* ========================================
   BD Roaming Direct - Stylesheet
   Modern, Responsive, Professional Design
   ======================================== */

/* CSS Variables */
:root {
    --primary-color: #0056b3;
    --primary-dark: #004494;
    --primary-light: #e7f1ff;
    --secondary-color: #28a745;
    --secondary-dark: #218838;
    --accent-color: #17a2b8;
    --text-dark: #343a40;
    --text-light: #6c757d;
    --text-white: #ffffff;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --bg-gradient: linear-gradient(135deg, #0056b3 0%, #004494 100%);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px -3px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px -4px rgba(0, 0, 0, 0.2);
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --border-radius-lg: 16px;
    --transition: all 0.3s ease;
    --font-en: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-bn: 'Noto Sans Bengali', 'Inter', sans-serif;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-en);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    overflow-x: hidden;
}

[lang="bn"] body {
    font-family: var(--font-bn);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-dark);
}

p {
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* ========================================
   Header Styles
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    padding: 15px 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.logo i {
    font-size: 1.8rem;
}

.logo .highlight {
    color: var(--secondary-color);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.whatsapp-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #25D366;
    color: white;
    border-radius: 50px;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

.whatsapp-btn:hover {
    background: #20BD5A;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.lang-toggle {
    display: flex;
    gap: 5px;
    background: var(--bg-light);
    padding: 5px;
    border-radius: 50px;
}

.lang-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 500;
    border-radius: 50px;
    transition: var(--transition);
    font-size: 0.9rem;
}

.lang-btn.active {
    background: var(--primary-color);
    color: white;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    position: relative;
    padding: 160px 0 100px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-gradient);
    z-index: -1;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(40, 167, 69, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(23, 162, 184, 0.3) 0%, transparent 50%),
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.8;
}

.hero-content {
    text-align: center;
    color: white;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 40px;
    opacity: 0.95;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 50px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

.btn-primary:hover {
    background: var(--secondary-dark);
    border-color: var(--secondary-dark);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-outline:hover {
    background: white;
    color: var(--primary-color);
    transform: translateY(-3px);
}

.btn-lg {
    padding: 18px 40px;
    font-size: 1.1rem;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Hero Stats */
.hero-stats {
    display: flex;
    justify-content: center;
    gap: 50px;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
}

.stat-label {
    font-size: 0.95rem;
    opacity: 0.9;
}

/* ========================================
   Section Divider
   ======================================== */
.section-divider {
    height: 80px;
    background: linear-gradient(to bottom, var(--bg-white), var(--bg-light));
    position: relative;
    overflow: hidden;
}

.section-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.section-divider i {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--primary-color);
    font-size: 1.5rem;
}

/* ========================================
   Features Section
   ======================================== */
.features {
    padding: 80px 0;
    background: var(--bg-white);
}

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

.section-title {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background: var(--bg-light);
    padding: 40px 30px;
    border-radius: var(--border-radius-lg);
    text-align: center;
    transition: var(--transition);
    border: 1px solid transparent;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
    background: white;
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    transition: var(--transition);
}

.feature-card:hover .feature-icon {
    background: var(--secondary-color);
    transform: scale(1.1);
}

.feature-icon i {
    font-size: 2rem;
    color: white;
}

.feature-title {
    font-size: 1.4rem;
    margin-bottom: 12px;
}

.feature-desc {
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.7;
}

/* ========================================
   Operators Section
   ======================================== */
.operators {
    padding: 60px 0;
    background: var(--bg-light);
}

.operators-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
}

.operator-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    font-weight: 600;
    color: var(--text-dark);
    transition: var(--transition);
}

.operator-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    color: var(--primary-color);
}

.operator-item i {
    font-size: 1.2rem;
    color: var(--primary-color);
}

/* ========================================
   Order Form Section
   ======================================== */
.order-section {
    padding: 80px 0;
    background: var(--bg-white);
}

.form-container {
    max-width: 700px;
    margin: 0 auto;
    background: white;
    padding: 50px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-xl);
    position: relative;
    overflow: hidden;
}

.form-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--bg-gradient);
}

/* Form Group */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-dark);
}

.form-group label i {
    color: var(--primary-color);
    font-size: 0.9rem;
}

.form-group label .required {
    color: #dc3545;
}

/* Input Fields */
.form-group input,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    font-size: 1rem;
    font-family: var(--font-en);
    border: 2px solid #e0e0e0;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
    background: white;
    color: var(--text-dark);
}

[lang="bn"] .form-group input,
[lang="bn"] .form-group select {
    font-family: var(--font-bn);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 86, 179, 0.1);
}

.form-group input::placeholder {
    color: #adb5bd;
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236c757d' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    padding-right: 45px;
}

/* Error State */
.form-group input.error,
.form-group select.error {
    border-color: #dc3545;
    background-color: #fff5f5;
}

.error-message {
    display: block;
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 5px;
    min-height: 20px;
}

/* reCAPTCHA */
.recaptcha-group {
    display: flex;
    justify-content: center;
    margin: 30px 0;
}

.g-recaptcha {
    transform: scale(0.9);
    transform-origin: center center;
}

/* Submit Button */
.roaming-form .btn-primary {
    margin-top: 10px;
    position: relative;
}

.roaming-form .btn-primary .btn-loader {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.roaming-form .btn-primary.loading .btn-loader {
    display: inline-block;
}

.roaming-form .btn-primary.loading span {
    opacity: 0;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 40px 20px;
}

.success-icon {
    width: 100px;
    height: 100px;
    background: var(--secondary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.success-icon i {
    font-size: 3rem;
    color: white;
}

.success-message h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.success-message p {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 25px;
}

/* Error Alert */
.error-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    background: #fff5f5;
    border: 1px solid #dc3545;
    border-radius: var(--border-radius-sm);
    color: #dc3545;
    margin-bottom: 20px;
}

.error-alert i {
    font-size: 1.2rem;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 60px 0 30px;
}

.footer-content {
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-logo i {
    font-size: 1.8rem;
    color: var(--primary-color);
}

.footer-logo .highlight {
    color: var(--secondary-color);
}

.footer-text {
    color: rgba(255, 255, 255, 0.7);
    max-width: 500px;
    margin: 0 auto 25px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ========================================
   Responsive Design
   ======================================== */

/* Tablet */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .form-container {
        padding: 40px 30px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .header {
        padding: 12px 0;
    }
    
    .logo {
        font-size: 1.2rem;
    }
    
    .logo i {
        font-size: 1.4rem;
    }
    
    .whatsapp-btn span {
        display: none;
    }
    
    .whatsapp-btn {
        padding: 10px 14px;
    }
    
    .hero {
        padding: 140px 0 70px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-lg {
        width: 100%;
        max-width: 280px;
    }
    
    .hero-stats {
        gap: 30px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .operators-grid {
        gap: 15px;
    }
    
    .operator-item {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
    
    .form-container {
        padding: 30px 20px;
        border-radius: var(--border-radius);
    }
    
    .form-group {
        margin-bottom: 20px;
    }
    
    .form-group input,
    .form-group select {
        padding: 12px 15px;
        font-size: 0.95rem;
    }
    
    .recaptcha-group {
        transform: scale(0.85);
        margin: 20px 0;
    }
    
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer-links {
        gap: 20px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 20px;
    }
    
    .lang-toggle {
        display: none;
    }
}

/* Print Styles */
@media print {
    .header,
    .hero-buttons,
    .footer {
        display: none;
    }
    
    .hero {
        padding: 20px 0;
    }
    
    .form-container {
        box-shadow: none;
    }
}

/* Animation for loading state */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Selection */
::selection {
    background: var(--primary-color);
    color: white;
}

/* Focus visible for accessibility */
*:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 3px solid var(--secondary-dark);
    }
    
    .form-group input,
    .form-group select {
        border-width: 3px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
