/**
 * Green Lab Web - Main Stylesheet
 * Medical Laboratory Management System
 */

/* Import Google Fonts - Cairo for Arabic */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;800&display=swap');

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

:root {
    /* Brand base (requested): #2c3e50 with graded shades */
    --brand-900: #1f2d3a;
    --brand-800: #243447;
    --brand-700: #2c3e50; /* base */
    --brand-600: #34495e;
    --brand-500: #3b556f;
    --brand-gradient: linear-gradient(135deg, var(--brand-900), var(--brand-600));
    --brand-gradient-soft: linear-gradient(135deg, var(--brand-800), var(--brand-500));

    /* Dark theme (match old footer color) */
    --site-bg: var(--brand-700);
    --site-surface: var(--brand-600);
    --site-surface-2: var(--brand-500);
    --site-text: #ffffff;
    --site-muted: #ffffff;
    --site-border: rgba(255,255,255,0.10);

    /* Keep existing variable names used across the file */
    --primary-green: var(--brand-500);
    --dark-green: var(--brand-900);
    --light-green: var(--brand-600);
    --white: #ffffff;
    --light-gray: var(--site-surface-2);
    --gray: rgba(255,255,255,0.20);
    --dark-gray: rgba(255,255,255,0.35);
    --text-dark: #0f1720;
    --text-light: #ffffff;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    
    /* Transitions */
    --transition: all 0.3s ease;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 20px rgba(0,0,0,0.15);
}

body {
    font-family: 'Cairo', sans-serif;
    direction: rtl;
    text-align: right;
    line-height: 1.8;
    color: var(--site-text);
    background-color: var(--site-bg);
}

/* Prevent accidental horizontal scroll on small screens (e.g., 100vw sections) */
html, body {
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    margin-bottom: var(--spacing-md);
    color: var(--white);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: var(--spacing-sm);
    color: var(--site-muted);
    line-height: 1.8;
}

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

a:hover {
    color: var(--white);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Override for feature icons - more specific */
.feature-card img.feature-icon,
.feature-card .feature-icon,
img.feature-icon {
    width: 100px !important;
    height: 100px !important;
    max-width: 100px !important;
    max-height: 100px !important;
    min-width: 100px !important;
    min-height: 100px !important;
    object-fit: contain !important;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.container-fluid {
    width: 100%;
    padding: 0 var(--spacing-md);
}

/* Header */
.header {
    background: var(--site-bg);
    box-shadow: none;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background: var(--brand-gradient);
    color: var(--white);
    padding: var(--spacing-xs) 0;
}

.header-top .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.country-name {
    font-weight: 600;
}

.header-main {
    padding: var(--spacing-sm) 0;
    background: var(--site-bg);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-lg);
}

.logo-section {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.logo {
    height: 60px;
    width: auto;
}

.site-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    margin: 0;
}

/* Navigation */
.main-nav ul {
    list-style: none;
    display: flex;
    gap: var(--spacing-lg);
    margin: 0;
}

.main-nav a {
    color: var(--white);
    font-weight: 600;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: 5px;
    transition: var(--transition);
}

.main-nav a:hover,
.main-nav a.active {
    background: var(--primary-green);
    color: var(--white);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: var(--primary-green);
    color: var(--white);
    border: none;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Hero Section */
.hero-section {
    background: var(--brand-gradient);
    color: var(--white);
    padding: var(--spacing-xl) 0;
    margin-bottom: var(--spacing-xl);
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 0;
}

.hero-section .container {
    position: relative;
    z-index: 1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: center;
}

.hero-text h1 {
    color: var(--white);
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
}

.hero-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    margin-bottom: var(--spacing-lg);
}

.hero-image img {
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
}

.btn {
    display: inline-block;
    padding: var(--spacing-sm) var(--spacing-lg);
    background: var(--brand-gradient);
    color: var(--white);
    font-weight: 700;
    border-radius: 50px;
    transition: var(--transition);
    border: 2px solid transparent;
    cursor: pointer;
    text-align: center;
}

.btn:hover {
    background: var(--brand-gradient-soft);
    color: var(--white);
}

.btn-primary {
    background: var(--brand-gradient);
    color: var(--white);
    border-color: transparent;
}

.btn-primary:hover {
    background: var(--brand-gradient-soft);
    border-color: transparent;
}

/* Section Styles */
.section {
    padding: var(--spacing-xl) 0;
    background: transparent;
    margin-bottom: var(--spacing-lg);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.section-title {
    font-size: 2.5rem;
    /* Force white titles across the site (avoid overrides) */
    color: var(--white) !important;
    margin-bottom: var(--spacing-sm);
}

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

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
}

/* Features Slider (Home) */
.features-slider-wrapper {
    position: relative;
    overflow: hidden;
    padding: 1rem 0 0.25rem;
}

/* Scroll-snap carousel (more stable than transform sliders) */
.features-carousel {
    display: flex;
    gap: var(--spacing-lg);
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 0.25rem 0.25rem 1rem;
    -webkit-overflow-scrolling: touch;
}

.features-carousel::-webkit-scrollbar {
    height: 8px;
}
.features-carousel::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.20);
    border-radius: 999px;
}
.features-carousel::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.08);
    border-radius: 999px;
}

.features-carousel .feature-card {
    scroll-snap-align: start;
    flex: 0 0 calc(33.333% - var(--spacing-lg));
    min-width: 280px;
}

.features-dots {
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    margin-top: 1rem;
    padding-bottom: 0.25rem;
}

.features-dots .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.22);
    cursor: pointer;
    transition: var(--transition);
}

.features-dots .dot.active {
    background: rgba(255,255,255,0.65);
    transform: scale(1.25);
}

.features-dots .dot:hover {
    background: rgba(255,255,255,0.45);
    transform: scale(1.15);
}

.feature-card {
    background: var(--site-surface);
    border-radius: 10px;
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid var(--site-border);
}

.feature-card .feature-icon {
    text-align: center;
}

.feature-card .feature-title {
    text-align: center;
    width: 100%;
}

.feature-description-wrapper {
    width: 100% !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

.feature-card .feature-description {
    text-align: right !important;
    direction: rtl !important;
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

.feature-card .feature-description *,
.feature-card .feature-description p,
.feature-card .feature-description div,
.feature-card .feature-description span,
.feature-card .feature-description h1,
.feature-card .feature-description h2,
.feature-card .feature-description h3,
.feature-card .feature-description h4,
.feature-card .feature-description h5,
.feature-card .feature-description h6,
.feature-card .feature-description ul,
.feature-card .feature-description ol,
.feature-card .feature-description li {
    text-align: right !important;
    direction: rtl !important;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 100px !important;
    height: 100px !important;
    max-width: 100px !important;
    max-height: 100px !important;
    object-fit: contain !important;
    border-radius: 10px;
    margin-bottom: var(--spacing-md);
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* Local placeholders (avoid external DNS calls) */
.feature-icon-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.10);
    border: 1px solid rgba(255,255,255,0.18);
    color: var(--white);
    font-size: 2rem;
}

.client-logo-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 10px;
    height: 150px; /* same as .client-logo */
    color: var(--white);
    padding: 1rem;
    text-align: center;
}

.client-logo-placeholder i {
    font-size: 2rem;
    opacity: 0.9;
}

.client-placeholder-text {
    font-size: 0.95rem;
    opacity: 0.95;
    line-height: 1.4;
}

.feature-title {
    font-size: 1.3rem;
    color: var(--white) !important;
    margin-bottom: var(--spacing-sm);
}

.feature-description {
    color: var(--site-muted);
    line-height: 1.8;
    text-align: right;
    direction: rtl;
}

.feature-description p {
    margin-bottom: var(--spacing-sm);
    text-align: right;
}

.feature-description ul,
.feature-description ol {
    text-align: right;
    padding-right: var(--spacing-md);
    padding-left: 0;
    margin-bottom: var(--spacing-sm);
    direction: rtl;
}

.feature-description li {
    margin-bottom: 0.5rem;
    text-align: right;
}

.feature-description h1,
.feature-description h2,
.feature-description h3,
.feature-description h4,
.feature-description h5,
.feature-description h6 {
    color: var(--white) !important;
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
    text-align: right;
}

.feature-description strong,
.feature-description b {
    color: var(--white) !important;
    font-weight: 600;
}

.feature-description a {
    color: var(--white);
    text-decoration: underline;
}

.feature-description a:hover {
    color: var(--white);
}

/* Clients Slider */
.clients-slider-wrapper {
    position: relative;
    overflow: hidden;
    padding: 1rem 0;
}

.clients-slider {
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 0.25rem 0.25rem 1rem;
    -webkit-overflow-scrolling: touch;
}

/* optional scrollbar styling */
.clients-slider::-webkit-scrollbar {
    height: 8px;
}
.clients-slider::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.20);
    border-radius: 999px;
}
.clients-slider::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.08);
    border-radius: 999px;
}

.client-card {
    background: var(--site-surface);
    padding: var(--spacing-lg);
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: var(--transition);
    scroll-snap-align: start;
    flex: 0 0 calc(25% - var(--spacing-lg));
    min-width: 250px;
    border: 1px solid var(--site-border);
}

.client-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-5px);
}

.client-logo {
    width: 100%;
    height: 150px;
    object-fit: contain;
    margin-bottom: var(--spacing-sm);
}

.client-name {
    font-weight: 600;
    color: var(--white);
}

/* Slider Controls */
.slider-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    padding: 0 1rem;
}

.slider-btn {
    background: var(--primary-green);
    color: var(--white);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: var(--transition);
    pointer-events: all;
    box-shadow: var(--shadow-md);
    z-index: 10;
}

.slider-btn:hover {
    background: var(--dark-green);
    transform: scale(1.1);
}

.slider-btn:active {
    transform: scale(0.95);
}

.prev-btn {
    right: 0;
}

.next-btn {
    left: 0;
}

/* (Old keyframes removed: slider is scroll-snap now) */

/* Responsive */
@media (max-width: 1200px) {
    .client-card {
        flex: 0 0 calc(33.333% - var(--spacing-lg));
    }
}

@media (max-width: 768px) {
    .client-card {
        flex: 0 0 calc(50% - var(--spacing-lg));
        min-width: 200px;
    }
    
    .slider-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .client-card {
        flex: 0 0 calc(100% - var(--spacing-lg));
    }
}

/* Contact Form */
.contact-section {
    background: var(--light-gray);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
}

.contact-info {
    background: var(--site-surface);
    padding: var(--spacing-lg);
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--site-border);
}

.contact-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    padding: var(--spacing-sm);
    background: var(--site-surface-2);
    border-radius: 8px;
}

.contact-icon {
    font-size: 1.5rem;
    color: var(--white);
}

.contact-text h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--white);
}

.contact-text p {
    margin: 0;
    color: var(--site-muted);
}

.contact-form {
    background: var(--site-surface);
    padding: var(--spacing-lg);
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--site-border);
}

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-label {
    display: block;
    margin-bottom: var(--spacing-xs);
    font-weight: 600;
    color: var(--white);
}

.form-control {
    width: 100%;
    padding: var(--spacing-sm);
    background: var(--site-surface-2);
    color: var(--site-text);
    border: 1px solid var(--site-border);
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-green);
}

textarea.form-control {
    min-height: 150px;
    resize: vertical;
}

/* Updates & Blog */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: var(--spacing-lg);
}

.post-card {
    background: var(--site-surface);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--site-border);
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.post-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.post-content {
    padding: var(--spacing-lg);
}

.post-meta {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
    font-size: 0.9rem;
    color: var(--site-muted);
}

.post-title {
    font-size: 1.4rem;
    margin-bottom: var(--spacing-sm);
    color: var(--white);
}

.post-excerpt {
    color: var(--site-muted);
    margin-bottom: var(--spacing-md);
}

.read-more {
    color: var(--white);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.read-more:hover {
    gap: 1rem;
}

/* Single Post/Update Page */
.single-post {
    background: var(--site-surface);
    padding: var(--spacing-xl);
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    max-width: 900px;
    margin: var(--spacing-xl) auto;
    border: 1px solid var(--site-border);
}

.post-header {
    margin-bottom: var(--spacing-lg);
}

.post-featured-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: var(--spacing-lg);
}

.post-body {
    line-height: 2;
    color: var(--site-text);
}

.post-body h3 {
    color: var(--white);
    margin-top: var(--spacing-lg);
}

.post-body ul, .post-body ol {
    margin: var(--spacing-md) 0;
    padding-right: var(--spacing-lg);
}

.post-body li {
    margin-bottom: var(--spacing-xs);
    color: var(--site-muted);
}

/* Footer */
.footer {
    /* Dark footer (site-wide theme) */
    background: var(--brand-gradient);
    color: var(--white);
    padding: var(--spacing-xl) 0 var(--spacing-md);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.footer-section h4 {
    color: var(--white);
    margin-bottom: var(--spacing-md);
}

.footer-section p {
    color: rgba(255,255,255,0.8);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: var(--spacing-xs);
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
}

.footer-links a:hover {
    color: var(--white);
    transform: translateX(-5px);
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: var(--spacing-sm);
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: var(--white);
    transition: var(--transition);
}

.social-link:hover {
    background: rgba(255,255,255,0.22);
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(255,255,255,0.1);
    color: var(--white);
}

/* App Screenshots Slider */
.app-screenshots-slider-wrapper {
    position: relative;
    width: 100vw;
    max-width: 100vw;
    margin: 0;
    padding: 0;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

/* Social icons bar above screenshots slider */
.slider-social-bar {
    /* Better visibility: a bar above the slider (not overlaying the image) */
    position: relative;
    z-index: 5;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.8rem 1rem;
    background: var(--brand-gradient);
    border-bottom: 1px solid rgba(255,255,255,0.12);
}

.slider-social-link {
    width: 52px;
    height: 52px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    background: rgba(255,255,255,0.12);
    transition: var(--transition);
    text-decoration: none;
}

.slider-social-link:hover {
    background: rgba(255,255,255,0.22);
    color: var(--white);
    transform: translateY(-1px);
}

.slider-social-link i {
    font-size: 1.4rem;
}

.app-screenshots-slider {
    display: flex;
    overflow: hidden;
    background: var(--light-gray);
    position: relative;
    min-height: 400px;
    width: 100%;
}

.screenshot-slide {
    min-width: 100%;
    width: 100%;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    transition: opacity 0.8s ease-in-out;
    z-index: 1;
    visibility: hidden;
}

.screenshot-slide.active {
    opacity: 1;
    z-index: 2;
    visibility: visible;
}

.screenshot-slide:first-child {
    position: relative;
}

.screenshot-image {
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: 400px;
    max-height: 600px;
    object-fit: contain;
    display: block;
    margin: 0 auto;
    background: var(--light-gray);
}

.screenshot-caption {
    padding: var(--spacing-lg);
    text-align: center;
    background: rgba(255, 255, 255, 0.95);
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    backdrop-filter: blur(10px);
}

.screenshot-caption h4 {
    color: var(--white);
    margin-bottom: var(--spacing-sm);
    font-size: 1.4rem;
    font-weight: bold;
}

.screenshot-caption p {
    color: var(--text-light);
    margin: 0;
    font-size: 1.1rem;
    line-height: 1.8;
}

.screenshot-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    padding: 0 1rem;
    z-index: 10;
}

.screenshot-btn {
    background: rgba(46, 204, 113, 0.9);
    color: var(--white);
    border: none;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    transition: var(--transition);
    pointer-events: all;
    box-shadow: var(--shadow-md);
}

.screenshot-btn:hover {
    background: var(--primary-green);
    transform: scale(1.15);
    box-shadow: var(--shadow-lg);
}

.screenshot-btn:active {
    transform: scale(0.95);
}

.screenshot-btn.prev-btn {
    right: 0;
}

.screenshot-btn.next-btn {
    left: 0;
}

.screenshot-dots {
    display: flex;
    justify-content: center;
    gap: 0.7rem;
    margin-top: 2rem;
}

.screenshot-dots .dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--gray);
    cursor: pointer;
    transition: var(--transition);
}

.screenshot-dots .dot.active {
    background: var(--primary-green);
    transform: scale(1.3);
}

.screenshot-dots .dot:hover {
    background: var(--dark-green);
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .screenshot-btn {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .screenshot-caption {
        padding: var(--spacing-md);
    }
    
    .screenshot-caption h4 {
        font-size: 1.2rem;
    }
    
    .screenshot-caption p {
        font-size: 1rem;
    }
    
    .screenshot-image {
        min-height: 300px;
        max-height: 400px;
    }
    
    .app-screenshots-slider {
        min-height: 300px;
    }
}

/* Alert Messages */
.alert {
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: 8px;
    margin-bottom: var(--spacing-md);
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-danger {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 0.9rem;
    }

    .header-top .container {
        flex-wrap: wrap;
        row-gap: 0.35rem;
        column-gap: 0.75rem;
        align-items: center;
        font-size: 0.85rem;
    }

    .header-content {
        /* One-line mobile header: logo/title + menu button */
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: var(--spacing-sm);
        position: relative; /* anchor dropdown to full header width */
    }

    .menu-toggle {
        display: block;
        padding: 0.6rem 0.85rem;
        font-size: 1.25rem;
        border-radius: 10px;
    }
    
    .main-nav {
        /* Keep nav visible so the toggle button is always accessible */
        display: flex;
        align-items: center;
        justify-content: flex-end;
        position: static; /* dropdown should anchor to .header-content, not the button width */
    }
    
    .main-nav ul {
        /* Collapse links by default on mobile */
        display: none;
        flex-direction: column;
        gap: var(--spacing-sm);
        position: absolute;
        top: calc(100% + 0.5rem);
        left: 0;
        right: 0;
        background: var(--site-surface);
        box-shadow: var(--shadow-md);
        padding: var(--spacing-md);
        border-radius: 10px;
        margin-top: var(--spacing-xs);
        z-index: 1001;
        max-height: 70vh;
        overflow: auto;
    }

    .main-nav.active ul {
        display: flex;
    }

    .logo-section {
        gap: 0.6rem;
    }

    .logo {
        height: 44px;
    }

    .site-title {
        font-size: 1.25rem;
        line-height: 1.2;
        margin: 0;
        white-space: nowrap;
    }

    .header-main {
        padding: 0.75rem 0;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        text-align: center;
    }
    
    .hero-text h1 {
        font-size: 2rem;
    }

    .hero-section {
        padding: var(--spacing-lg) 0;
        margin-bottom: var(--spacing-lg);
        background-attachment: scroll;
    }

    .hero-text p {
        font-size: 1.05rem;
    }

    .hero-text .btn {
        width: 100%;
        max-width: 420px;
        margin: 0 auto;
        display: block;
    }

    .section {
        padding: var(--spacing-lg) 0;
        margin-bottom: var(--spacing-md);
    }

    .section-header {
        margin-bottom: var(--spacing-lg);
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .features-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }

    .features-carousel .feature-card {
        flex: 0 0 calc(100% - var(--spacing-lg));
        min-width: 260px;
    }

    .features-grid {
        gap: var(--spacing-md);
    }

    .feature-card {
        padding: var(--spacing-md);
    }
    
    .section-title {
        font-size: 1.8rem;
        color: var(--white) !important;
    }

    .section-subtitle {
        font-size: 1rem;
    }

    .post-meta {
        flex-wrap: wrap;
        row-gap: 0.25rem;
    }
    
    .post-featured-image {
        height: 250px;
    }

    /* App Screenshots slider - avoid 100vw tricks causing overflow on mobile */
    .app-screenshots-slider-wrapper {
        width: 100%;
        max-width: 100%;
        left: auto;
        right: auto;
        margin-left: 0;
        margin-right: 0;
    }

    .app-screenshots-slider,
    .screenshot-slide {
        min-height: 260px;
    }

    .screenshot-image {
        min-height: 260px;
        max-height: 60vh;
        object-fit: contain;
    }

    .screenshot-caption {
        padding: var(--spacing-md);
    }

    .screenshot-caption h4 {
        font-size: 1.15rem;
    }

    .screenshot-caption p {
        font-size: 0.95rem;
    }

    .screenshot-dots {
        margin-top: 1rem;
        padding-bottom: 0.5rem;
    }

    .slider-social-bar {
        gap: 0.5rem;
        padding: 0.6rem 0.75rem;
    }

    .slider-social-link {
        width: 48px;
        height: 48px;
    }
}

@media (max-width: 1200px) {
    .features-carousel .feature-card {
        flex: 0 0 calc(50% - var(--spacing-lg));
    }
}

@media (max-width: 480px) {
    .site-title {
        font-size: 1.2rem;
    }

    .logo {
        height: 48px;
    }

    .hero-text h1 {
        font-size: 1.7rem;
    }

    .hero-text p {
        font-size: 0.98rem;
    }

    .section-title {
        font-size: 1.55rem;
        color: var(--white) !important;
    }

    .app-screenshots-slider,
    .screenshot-slide {
        min-height: 220px;
    }

    .screenshot-image {
        min-height: 220px;
        max-height: 55vh;
    }
}

/* Loading Spinner */
.spinner {
    border: 3px solid var(--gray);
    border-top: 3px solid var(--primary-green);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: var(--spacing-lg) auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.mt-1 { margin-top: var(--spacing-sm); }
.mt-2 { margin-top: var(--spacing-md); }
.mt-3 { margin-top: var(--spacing-lg); }
.mb-1 { margin-bottom: var(--spacing-sm); }
.mb-2 { margin-bottom: var(--spacing-md); }
.mb-3 { margin-bottom: var(--spacing-lg); }
.p-1 { padding: var(--spacing-sm); }
.p-2 { padding: var(--spacing-md); }
.p-3 { padding: var(--spacing-lg); }

