/* ============================================
   SchoolCountry Home Page - Simple Mobile First
   ============================================ */

/* CSS Variables - SchoolCountry Colors */
:root {
    --primary-blue: #021f69;
    --secondary-blue: #0072bc;
    --accent-purple: #820fa8;
    --accent-green: #77dd44;
    --accent-green-light: #a6ff71;
    --red: #ff0000;
    --white: #fff;
    --text-dark: #000;
    --text-gray: #5d5d5d;
    --text-gray-light: #595959;
    --shadow: rgba(0, 0, 0, 0.15);
}

/* Reset & Base */
* {
    box-sizing: border-box;
}

.home-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

/* ===== Image Slider (Swiper) ===== */
.image-slider {
    width: 100%;
    position: relative;
    margin-bottom: 2rem;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px var(--shadow);
    height: 300px; /* Fixed height for mobile */
    min-height: 300px;
    background: var(--primary-blue);
}

.image-slider .swiper {
    width: 100%;
    height: 100%;
    position: relative;
}

.image-slider .swiper-wrapper {
    width: 100%;
    height: 100%;
}

.image-slider .swiper-slide {
    width: 100%;
    height: 100%;
    position: relative;
}

.image-slider .swiper-slide img {
    display: block;
}

.slide-image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-blue);
}

.slide-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(2, 31, 105, 0.9), transparent);
    color: var(--white);
    padding: 2rem 1.5rem 1.5rem;
    text-align: center;
    z-index: 2;
}

.slide-content h2 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    color: var(--white);
    font-weight: bold;
}

.slide-content p {
    margin: 0;
    font-size: 1rem;
}

/* Swiper Navigation Buttons */
.image-slider .swiper-button-next,
.image-slider .swiper-button-prev {
    background: rgba(255, 255, 255, 0.8);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: var(--primary-blue);
    transition: all 0.3s;
}

.image-slider .swiper-button-next:after,
.image-slider .swiper-button-prev:after {
    font-size: 1.2rem;
    font-weight: bold;
}

.image-slider .swiper-button-next:hover,
.image-slider .swiper-button-prev:hover {
    background: var(--white);
    box-shadow: 0 2px 8px var(--shadow);
}

/* Swiper Pagination */
.image-slider .swiper-pagination {
    bottom: 20px !important;
}

.image-slider .swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 1;
    transition: all 0.3s;
}

.image-slider .swiper-pagination-bullet-active {
    background: var(--white);
    width: 30px;
    border-radius: 6px;
}

/* ===== Product Cards Slider ===== */
.products-section {
    margin: 2rem 0;
}

.products-slider {
    width: 100%;
    position: relative;
    padding: 0 0 50px 0;
}

/* Mobile: Reduce padding for navigation buttons */
@media (max-width: 767px) {
    .products-slider {
        padding: 0 0 50px 0;
    }

    .category-image {
        height: 160px;
    }

    .category-content {
        padding: 1.25rem;
    }

    .category-name {
        font-size: 1.3rem;
    }

    .category-desc {
        font-size: 0.9rem;
    }

    .category-cta {
        padding: 1rem;
        font-size: 0.95rem;
        background: rgb(255, 228, 76);
    }

    .category-cta:hover {
        background: rgb(255, 235, 120);
    }

    .trust-card-header {
        padding: 1rem;
    }

    .trust-card-title {
        font-size: 1.1rem;
    }

    .trust-card-body {
        padding: 0.5rem;
    }
}

.products-swiper {
    width: 100%;
    padding-bottom: 20px;
    overflow: hidden;
}

.products-swiper .swiper-wrapper {
    display: flex;
}

.products-swiper .swiper-slide {
    height: auto;
    display: flex;
    flex-shrink: 0;
    box-sizing: border-box;
}

.products-swiper .swiper-slide .category-card {
    width: 100%;
}

/* Category Card Design */
.category-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px var(--shadow);
    transition: all 0.3s ease;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #e0e0e0;
    box-sizing: border-box;
}

.category-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: var(--primary-blue);
}

.category-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    background: var(--primary-blue);
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.category-card:hover .category-image img {
    transform: scale(1.05);
}

.category-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.category-name {
    color: var(--primary-blue);
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 0 1rem 0;
    text-align: center;
}

.category-desc {
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0 0 1.5rem 0;
    flex-grow: 1;
    text-align: left;
}

.category-cta {
    display: inline-block;
    background: rgb(255, 228, 76);
    color: var(--text-dark);
    padding: 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px var(--shadow);
    border: 2px solid transparent;
    margin-top: auto;
}

.category-cta:hover {
    background: rgb(255, 235, 120);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px var(--shadow);
    color: var(--text-dark);
}

/* Legacy product-card class for backward compatibility */
.product-card {
    background: var(--white);
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px var(--shadow);
    transition: all 0.3s;
    text-align: center;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}


/* Products Slider Pagination */
.products-swiper .swiper-pagination {
    bottom: 0 !important;
}

.products-swiper .swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background: #ccc;
    opacity: 1;
    transition: all 0.3s;
}

.products-swiper .swiper-pagination-bullet-active {
    background: var(--primary-blue);
    width: 30px;
    border-radius: 6px;
}

/* Video in Welcome Card */
.video-container {
    margin: 1rem 0;
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    border-radius: 8px;
    overflow: hidden;
    background: var(--text-dark);
}

.video-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.video-wrapper iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.video-thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-button-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: url('/blog/pics/playStrip.png') no-repeat center;
    background-size: contain;
    cursor: pointer;
}

/* ===== Trust Section ===== */
.trust-section {
    margin: 2rem 0;
}

.trust-cards-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.trust-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid #e0e0e0;
    display: flex;
    flex-direction: column;
}

.trust-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-blue);
}

.trust-card-header {
    background: var(--accent-green-light);
    padding: 1.25rem;
    text-align: center;
}

.trust-card-title {
    color: var(--primary-blue);
    font-size: 1.2rem;
    font-weight: bold;
    margin: 0;
}

.trust-card-body {
    padding: 0.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.testimonial-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 8px;
}

.testimonial-item:last-of-type {
    margin-bottom: 1rem;
}

.testimonial-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.testimonial-text {
    flex: 1;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-dark);
}

.testimonial-author {
    font-size: 0.85rem;
    color: var(--text-gray-light);
    margin-top: 0.5rem;
    font-style: italic;
}

.press-item {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 8px;
    text-align: center;
}

.press-item:last-of-type {
    margin-bottom: 1rem;
}

.press-logo {
    max-width: 200px;
    height: auto;
    margin: 0 auto 1rem;
    display: block;
}

.press-quote {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-dark);
    font-style: italic;
}

.expert-content {
    padding: 0;
    background: transparent;
    border-radius: 0;
}

.expert-text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-gray);
    margin-bottom: 1rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 8px;
}

.expert-image {
    max-width: 150px;
    height: auto;
    margin: 1rem auto;
    display: block;
}

.trust-links {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid var(--accent-green-light);
}

.trust-link {
    color: var(--primary-blue);
    text-decoration: underline;
    font-size: 1rem;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.trust-link img {
    max-width: 16px;
    height: auto;
}

/* ===== CTA Section ===== */
.cta-section {
    background: var(--white);
    border-radius: 10px;
    padding: 1.5rem;
    margin: 2rem 0;
    box-shadow: 0 2px 4px var(--shadow);
}

.cta-divider {
    height: 28px;
    width: 100%;
    background: url('blog/pics/circle.jpg') repeat-x;
    margin: 1rem 0;
}

.cta-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    text-align: center;
}

.cta-image {
    max-width: 200px;
    height: auto;
}

.cta-text {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-gray);
    max-width: 600px;
}

.cta-text strong {
    color: var(--primary-blue);
}

/* ===== Email Modal ===== */
#register {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

#register.show {
    display: flex;
}

.register-modal {
    background: var(--white);
    border-radius: 10px;
    padding: 2rem;
    max-width: 400px;
    width: 100%;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.register-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-gray);
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    line-height: 1;
}

.register ul {
    margin: 1rem 0 1.5rem 2rem;
    padding: 0;
    list-style: disc;
}

.register li {
    margin: 0.5rem 0;
    font-size: 0.95rem;
}

.register-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.register-label {
    font-size: 1.1rem;
    font-weight: bold;
}

.register-input {
    width: 100%;
    padding: 0.75rem;
    font-size: 1rem;
    border: 1px solid var(--text-gray);
    border-radius: 5px;
    background: #eee;
}

.register-error {
    color: var(--red);
    font-size: 0.9rem;
}

.register-submit {
    background: var(--primary-blue);
    color: var(--white);
    border: none;
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    margin-top: 0.5rem;
}

.register-submit:hover {
    background: var(--secondary-blue);
}

/* ===== Tablet (768px+) ===== */
@media (min-width: 768px) {
    .home-container {
        padding: 1.5rem;
    }

    .image-slider {
        height: 400px;
    }

    .slide-content h2 {
        font-size: 2rem;
    }

    .slide-content p {
        font-size: 1.2rem;
    }

    .products-slider {
        padding: 0 0 50px 0;
    }

    .category-image {
        height: 180px;
    }

    .category-content {
        padding: 1.75rem;
    }

    .category-name {
        font-size: 1.4rem;
    }

    .trust-cards-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }

    .trust-card-header {
        padding: 1.5rem;
    }

    .trust-card-title {
        font-size: 1.3rem;
    }

    .trust-card-body {
        padding: 0.5rem;
    }

    .cta-content {
        flex-direction: row;
        text-align: left;
    }

    .cta-text {
        text-align: left;
        font-size: 1.1rem;
    }
}

/* ===== Desktop (1024px+) ===== */
@media (min-width: 1024px) {
    .home-container {
        padding: 2rem;
    }

    .image-slider {
        height: 500px;
    }

    .products-slider {
        padding: 0 0 50px 0;
    }


    .category-card {
        border-radius: 16px;
    }

    .category-image {
        height: 220px;
    }

    .category-content {
        padding: 2rem;
    }

    .category-name {
        font-size: 1.75rem;
    }

    .category-desc {
        font-size: 1rem;
    }

    .category-cta {
        padding: 1rem;
        font-size: 1.1rem;
        background: rgb(255, 228, 76);
    }

    .category-cta:hover {
        background: rgb(255, 235, 120);
    }

    .trust-cards-grid {
        gap: 2.5rem;
    }

    .trust-card-header {
        padding: 1.75rem;
    }

    .trust-card-title {
        font-size: 1.4rem;
    }

    .trust-card-body {
        padding: 0.5rem;
    }

    .product-card {
        padding: 2rem;
    }

    .product-card h3 {
        font-size: 1.5rem;
    }
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.round5 {
    border-radius: 5px;
}

.round10 {
    border-radius: 10px;
}
