/* ==========================================================================
   SilaMaths - A-Level Mathematics Home Tuition
   Custom Styles (styles.css)
   ========================================================================== */

/* CSS Variables */
:root {
    --primary-navy: #1e3a5f;
    --primary-orange: #ff6b35;
    --light-gray: #f8f9fa;
    --white: #ffffff;
    --text-dark: #2c3e50;
    --success-green: #28a745;
    --shadow-light: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-medium: 0 10px 30px rgba(0,0,0,0.1);
    --shadow-heavy: 0 15px 40px rgba(0,0,0,0.15);
    --transition-base: all 0.3s ease;
    --border-radius: 15px;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    overflow-x: hidden;
}

/* Accessibility */
.skip-to-main {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary-navy);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
}

.skip-to-main:focus {
    top: 6px;
}

/* Navigation */
.navbar {
    background: var(--white) !important;
    box-shadow: var(--shadow-light);
    transition: var(--transition-base);
    padding: 1rem 0;
}

.navbar.scrolled {
    padding: 0.5rem 0;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
    color: var(--primary-navy) !important;
    transition: var(--transition-base);
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.navbar-nav .nav-link {
    color: var(--primary-navy) !important;
    font-weight: 500;
    margin: 0 10px;
    position: relative;
    transition: var(--transition-base);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-orange) !important;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--primary-orange);
    transition: var(--transition-base);
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    width: 100%;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-navy) 0%, #2c5f87 100%);
    color: white;
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    line-height: 1.2;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 30px;
    opacity: 0.9;
    max-width: 500px;
}

.hero-buttons {
    margin-bottom: 40px;
}

.hero-buttons .btn {
    margin-right: 15px;
    margin-bottom: 10px;
}

.hero-image i {
    font-size: 15rem;
    color: rgba(255,255,255,0.1);
    animation: float 6s ease-in-out infinite;
}

/* Achievement Badges */
.achievement-badges {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.badge-item {
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    padding: 20px 15px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    min-width: 120px;
}

.badge-item strong {
    display: block;
    font-size: 2rem;
    color: var(--primary-orange);
    font-weight: bold;
}

.badge-item span {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Buttons */
.btn-primary {
    background: var(--primary-orange);
    border: none;
    padding: 12px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition-base);
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    background: #e55a2b;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 53, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.8);
    color: white;
    padding: 12px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition-base);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-outline-light:hover {
    background: white;
    color: var(--primary-navy);
    transform: translateY(-2px);
}

.btn-success {
    background: var(--success-green);
    border: none;
    border-radius: 50px;
    padding: 12px 25px;
    font-weight: 600;
    transition: var(--transition-base);
}

.btn-success:hover {
    background: #218838;
    transform: translateY(-2px);
}

.btn-whatsapp {
    background: #25d366;
    border: none;
}

.btn-whatsapp:hover {
    background: #128c7e;
}

/* Sections */
.section {
    padding: 80px 0;
    position: relative;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--primary-navy);
    margin-bottom: 15px;
    position: relative;
    font-weight: bold;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary-orange);
    border-radius: 2px;
}

.section-title .lead {
    font-size: 1.2rem;
    color: #6c757d;
    margin-top: 15px;
}

/* About Section */
.about {
    background: var(--light-gray);
}

.about-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow-medium);
    height: 100%;
    transition: var(--transition-base);
    text-align: center;
}

.about-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.about-icon {
    font-size: 3rem;
    color: var(--primary-orange);
    margin-bottom: 20px;
}

.about-card h3 {
    color: var(--primary-navy);
    margin-bottom: 20px;
    font-size: 1.5rem;
}

/* Programs Section */
.program-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-medium);
    border-left: 5px solid var(--primary-orange);
    transition: var(--transition-base);
    height: 100%;
}

.program-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.program-icon {
    font-size: 2.5rem;
    color: var(--primary-navy);
    margin-bottom: 20px;
}

.program-card h3 {
    color: var(--primary-navy);
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.program-details {
    background: var(--light-gray);
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
}

.program-details p {
    margin-bottom: 5px;
}

.program-features {
    list-style: none;
    padding: 0;
    margin-top: 20px;
}

.program-features li {
    padding: 5px 0;
    color: #6c757d;
}

.subjects-covered {
    background: linear-gradient(135deg, var(--primary-navy), #2c5f87);
    color: white;
    border-left: none;
}

.subjects-covered h3 {
    color: white;
}

.subjects-covered i {
    font-size: 2rem !important;
    color: var(--primary-orange) !important;
}

.subjects-covered h4 {
    color: white;
    margin-top: 15px;
    margin-bottom: 10px;
}

/* Testimonials Section */
.testimonials {
    background: var(--light-gray);
}

.testimonial-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow-medium);
    transition: var(--transition-base);
    height: 100%;
    position: relative;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.testimonial-content {
    position: relative;
    margin-bottom: 20px;
}

.quote-icon {
    font-size: 2rem;
    color: var(--primary-orange);
    opacity: 0.3;
    position: absolute;
    top: -10px;
    left: -10px;
}

.testimonial-content p {
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.7;
    margin-left: 20px;
}

.testimonial-author {
    border-top: 2px solid var(--light-gray);
    padding-top: 20px;
}

.testimonial-author strong {
    color: var(--primary-navy);
    font-size: 1.1rem;
}

.testimonial-author span {
    color: #6c757d;
    font-size: 0.9rem;
    display: block;
    margin-top: 5px;
}

.rating {
    margin-top: 10px;
}

.rating i {
    color: #ffc107;
    font-size: 0.9rem;
}

/* Pricing Section */
.pricing {
    background: var(--light-gray);
}

.pricing-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-medium);
    transition: var(--transition-base);
    height: 100%;
    position: relative;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.pricing-card.featured {
    border: 3px solid var(--primary-orange);
    transform: scale(1.05);
}

.pricing-card.featured:hover {
    transform: scale(1.08) translateY(-5px);
}

.popular-badge {
    position: absolute;
    top: 20px;
    right: -35px;
    background: var(--primary-orange);
    color: white;
    padding: 8px 40px;
    font-size: 0.8rem;
    font-weight: bold;
    transform: rotate(45deg);
    text-transform: uppercase;
    z-index: 2;
}

.pricing-header {
    background: var(--primary-navy);
    color: white;
    padding: 30px 20px;
    text-align: center;
}

.pricing-header h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 5px;
}

.currency {
    font-size: 1.2rem;
    font-weight: 600;
}

.amount {
    font-size: 3rem;
    font-weight: bold;
}

.period {
    font-size: 1rem;
    opacity: 0.8;
}

.pricing-features {
    padding: 30px 20px;
}

.pricing-features ul {
    list-style: none;
    padding: 0;
}

.pricing-features li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features i {
    color: var(--success-green);
    margin-right: 10px;
}

.pricing-note {
    background: rgba(255, 107, 53, 0.1);
    border: 1px solid rgba(255, 107, 53, 0.2);
    border-radius: 10px;
    padding: 20px;
    color: var(--text-dark);
}

/* Contact Section */
.contact {
    background: var(--primary-navy);
    color: white;
}

.contact .section-title h2 {
    color: white;
}

.contact .section-title h2::after {
    background: var(--primary-orange);
}

.contact .section-title .lead {
    color: rgba(255, 255, 255, 0.8);
}

.contact-form {
    background: rgba(255,255,255,0.1);
    padding: 40px;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
}

.contact-form h3 {
    color: white;
}

.form-control {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 15px;
    border-radius: 10px;
    transition: var(--transition-base);
}

.form-control:focus {
    background: rgba(255,255,255,0.2);
    border-color: var(--primary-orange);
    box-shadow: 0 0 0 0.2rem rgba(255, 107, 53, 0.25);
    color: white;
}

.form-control::placeholder {
    color: rgba(255,255,255,0.7);
}

.form-control.is-invalid {
    border-color: #dc3545;
}

.invalid-feedback {
    display: block;
    color: #ffc107;
    font-size: 0.875rem;
    margin-top: 5px;
}

.contact-info {
    background: rgba(255,255,255,0.1);
    padding: 40px;
    border-radius: var(--border-radius);
}

.contact-info h3,
.contact-info h4 {
    color: white;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-orange);
    margin-right: 15px;
    width: 30px;
    margin-top: 5px;
}

.contact-item h4 {
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.contact-item p,
.contact-item a {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0;
    text-decoration: none;
    transition: var(--transition-base);
}

.contact-item a:hover {
    color: var(--primary-orange);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    text-decoration: none;
    transition: var(--transition-base);
}

.social-link:hover {
    background: var(--primary-orange);
    color: white;
    transform: translateY(-2px);
}

/* Footer */
.footer {
    background: #0d1929;
    color: white;
    padding: 60px 0 20px;
}

.footer-section h5 {
    color: var(--primary-orange);
    margin-bottom: 20px;
    font-weight: bold;
}

.footer-section h6 {
    color: white;
    margin-bottom: 15px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition-base);
}

.footer-links a:hover {
    color: var(--primary-orange);
    padding-left: 5px;
}

.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-contact li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.footer-contact a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition-base);
}

.footer-contact a:hover {
    color: var(--primary-orange);
}

.footer-social {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.footer-divider {
    border-color: rgba(255, 255, 255, 0.1);
    margin: 40px 0 20px;
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 0;
    font-size: 0.9rem;
}

.footer-links-inline {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    align-items: center;
}

.footer-links-inline a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition-base);
}

.footer-links-inline a:hover {
    color: var(--primary-orange);
}

/* Back to Top Button */
.btn-back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-orange);
    color: white;
    border: none;
    border-radius: 50%;
    box-shadow: var(--shadow-medium);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-base);
    z-index: 1000;
}

.btn-back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.btn-back-to-top:hover {
    background: #e55a2b;
    transform: translateY(-2px);
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.active {
    opacity: 1;
    transform: translateY(0);
}

/* Math symbols decoration */
.math-symbol {
    position: absolute;
    color: rgba(255, 107, 53, 0.1);
    font-size: 4rem;
    font-weight: bold;
    z-index: 1;
    animation: float 6s ease-in-out infinite;
    user-select: none;
    pointer-events: none;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

.symbol-1 { 
    top: 20%; 
    left: 10%; 
    animation-delay: 0s; 
}

.symbol-2 { 
    top: 60%; 
    right: 15%; 
    animation-delay: 2s; 
}

.symbol-3 { 
    bottom: 30%; 
    left: 20%; 
    animation-delay: 4s; 
}

/* Loading States */
.button-loading {
    pointer-events: none;
}

/* Form Validation */
.was-validated .form-control:valid {
    border-color: var(--success-green);
}

.was-validated .form-control:invalid {
    border-color: #dc3545;
}

/* styles.css */
select#program option {
    color: #2d4e6e;
    background-color: #f8f9fa;
}

select#category option {
    color: #2d4e6e;
    background-color: #f8f9fa;
}

.profile-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #e0e0e0;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    margin: 1rem 0 1.5rem 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

/* Alternative smaller size option */
.profile-image-small {
    width: 120px;
    height: 120px;
}

/* Alternative larger size option */
.profile-image-large {
    width: 250px;
    height: 250px;
}

.paper-links {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.paper-link {
    /* background: linear-gradient(45deg, #007bff, #0056b3); */
    background: linear-gradient(45deg, #ff6b35, #fd4c0b);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
}

.paper-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.paper-link:hover::before {
    left: 100%;
}

.paper-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 123, 255, 0.3);
    color: white;
    text-decoration: none;
    background: linear-gradient(45deg, #0056b3, #004085);
}

.topic-list {
            list-style: none;
            padding: 0;
        }
        
        .topic-list li {
            background: white;
            padding: 0.75rem 1rem;
            margin-bottom: 0.5rem;
            border-radius: 10px;
            border-left: 4px solid #fd4c0b;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
            transition: all 0.3s ease;
        }
        
        .topic-list li:hover {
            transform: translateX(10px);
            box-shadow: 0 4px 15px rgba(0, 123, 255, 0.2);
        }
        
        .topic-list i {
            color: #1e3a5f;
            margin-right: 0.5rem;
            width: 20px;
        }

/* Responsive Design */
@media (max-width: 1200px) {
    .achievement-badges {
        justify-content: center;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
}

@media (max-width: 992px) {
    .navbar-collapse {
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 10px;
        margin-top: 10px;
        padding: 20px;
    }
    
    .hero {
        text-align: center;
        padding: 100px 0 60px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .achievement-badges {
        justify-content: center;
        gap: 15px;
    }
    
    .badge-item {
        min-width: 100px;
        padding: 15px 10px;
    }
    
    .pricing-card.featured {
        transform: none;
        margin-top: 20px;
    }
    
    .pricing-card.featured:hover {
        transform: translateY(-5px);
    }

    .profile-image {
        width: 150px;
        height: 150px;
    }   
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    .hero-buttons .btn {
        margin-right: 0;
        width: 100%;
        max-width: 300px;
    }
    .hero-image i {
        font-size: 10rem;
    }
    .testimonial-card {
        padding: 20px;
    }
    .testimonial-content p {
        font-size: 1rem;
    }
    .testimonial-author strong {
        font-size: 1rem;
    }
    .testimonial-author span {
        font-size: 0.8rem;
    }
    .pricing-card {
        padding: 20px;
    }
    .pricing-header h3 {
        font-size: 1.3rem;
    }
    .price {
        flex-direction: column;
        align-items: center;
    }
    .price .amount {
        font-size: 2.5rem;
    }
    .price .period {
        font-size: 0.9rem;
    }
    .pricing-features li {
        padding: 8px 0;
    }
    .pricing-features i {
        font-size: 0.9rem;
    }
    .contact-form {
        padding: 30px;
    }
    .contact-form h3 {
        font-size: 1.5rem;
    }
    .form-control {
        padding: 12px;
        font-size: 0.9rem;
    }
    .contact-info {
        padding: 30px;
    }
    .contact-info h3,
    .contact-info h4 {
        font-size: 1.2rem;
    }
    .contact-item {
        flex-direction: column;
        align-items: flex-start;
    }
    .contact-item i {
        margin-bottom: 10px;
    }
    .contact-item h4 {
        font-size: 1rem;
    }
    .contact-item p,
    .contact-item a {
        font-size: 0.9rem;
    }
    .footer {
        padding: 40px 0 20px;
    }
    .footer-section h5 {
        font-size: 1.2rem;
    }
    .footer-section h6 {
        font-size: 0.8rem;
    }
    .footer-section p {
        font-size: 0.9rem;
    }
    .footer-links a {
        font-size: 0.9rem;
    }
    .footer-contact a {
        font-size: 0.9rem;
    }
    .footer-social {
        flex-wrap: wrap;
        justify-content: center;
    }
    .footer-social .social-link {
        width: 35px;
        height: 35px;
    }
    .footer-social .social-link i {
        font-size: 1.2rem;
    }
    .footer-copyright {
        font-size: 0.8rem;
    }
    .footer-links-inline {
        flex-direction: column;
        align-items: center;
    }
    .footer-links-inline a {
        font-size: 0.8rem;
        margin-bottom: 5px;
    }
    .btn-back-to-top {
        width: 40px;
        height: 40px;
        bottom: 20px;
        right: 20px;
    }
    .btn-back-to-top i {
        font-size: 1.5rem;
    }
    .math-symbol {
        font-size: 3rem;
    }
    .math-symbol.symbol-1 {
        top: 15%;
        left: 5%;
    }
    .math-symbol.symbol-2 {
        top: 50%;
        right: 10%;
    }
    .math-symbol.symbol-3 {
        bottom: 20%;
        left: 10%;
    }

    .profile-image {
        width: 150px;
        height: 150px;
    }    
}
