/*
Theme Name: FirstTel
Theme URI: https://firsttel.ca
Author: FirstTel Team
Author URI: https://firsttel.ca
Description: A modern, hand-coded WordPress theme for FirstTel telecommunications services, inspired by AT&T's design aesthetics
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: firsttel
Tags: telecommunications, business, modern, responsive
*/

/* ============================================
   CSS RESET & BASE STYLES
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Primary Brand Colors - Inspired by AT&T */
    --primary-blue: #0057B8;
    --primary-dark-blue: #003d82;
    --primary-light-blue: #0077CC;
    --accent-cyan: #00A8E1;
    --accent-teal: #009FDB;

    /* Secondary Colors */
    --secondary-orange: #FF6B35;
    --secondary-green: #00C389;
    --secondary-purple: #6B4CE6;

    /* Neutral Colors */
    --white: #FFFFFF;
    --light-gray: #F5F7FA;
    --medium-gray: #E1E8ED;
    --dark-gray: #4A5568;
    --darker-gray: #2D3748;
    --black: #1A202C;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #0057B8 0%, #00A8E1 100%);
    --gradient-secondary: linear-gradient(135deg, #6B4CE6 0%, #00C389 100%);
    --gradient-overlay: linear-gradient(180deg, rgba(0, 87, 184, 0.9) 0%, rgba(0, 168, 225, 0.8) 100%);

    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Outfit', 'Inter', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
    --spacing-3xl: 6rem;

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.2);

    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-base: 300ms ease-in-out;
    --transition-slow: 500ms ease-in-out;
}

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@300;400;500;600;700;800;900&display=swap');

/* ============================================
   GLOBAL STYLES
   ============================================ */
html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--darker-gray);
    background-color: var(--white);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--black);
    margin-bottom: var(--spacing-md);
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

h5 {
    font-size: 1.125rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: var(--spacing-md);
    color: var(--dark-gray);
}

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-light-blue);
}

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

/* ============================================
   UTILITY CLASSES
   ============================================ */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.container-wide {
    max-width: 1400px;
}

.container-narrow {
    max-width: 900px;
}

.section {
    padding: var(--spacing-3xl) 0;
}

.section-sm {
    padding: var(--spacing-xl) 0;
}

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

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Cards & Grids */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
    height: 100%;
    text-align: left;
}

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

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
    margin: var(--spacing-xl) 0;
}

@media (max-width: 992px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

.features-grid .card {
    text-align: left;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-block;
    padding: 20px 80px;
    font-size: x-large;
    font-weight: 600;
    text-align: center;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all var(--transition-base);
    text-decoration: none;
    font-family: var(--font-primary);
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--white);
}

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

.btn-secondary:hover {
    background: var(--primary-blue);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-outline:hover {
    background: var(--white);
    color: var(--primary-blue);
}

.btn-large {
    padding: 1.25rem 3rem;
    font-size: 1.125rem;
}

.btn-small {
    padding: 0.625rem 1.5rem;
    font-size: 0.875rem;
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
.site-header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 95%;
    max-width: 1600px;
    /* Increased width */
    z-index: 1000;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    border-radius: 50px;
    /* More pill-shaped */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    /* Softer shadow */
    transition: all var(--transition-base);
    padding: 10px 30px;
    /* Reduced vertical padding */
}

.site-header.scrolled {
    top: 0;
    width: 100%;
    max-width: 100%;
    border-radius: 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-main .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
    width: 100%;
    max-width: 100%;
}

.site-logo img {
    height: 40px;
    /* Constrain logo height */
    width: auto;
}

.main-navigation {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    margin: 0 20px;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: 20px;
    /* Reduced gap */
    margin: 0;
    padding: 0;
    align-items: center;
    flex-wrap: nowrap;
    /* Prevent wrapping */
}

.main-navigation a {
    color: var(--dark-gray);
    font-weight: 600;
    font-size: 0.9rem;
    /* Slightly smaller text */
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 20px;
    transition: color 0.2s;
    white-space: nowrap;
    /* Prevent text wrapping */
}

.main-navigation a:hover,
.main-navigation .current-menu-item>a,
.main-navigation .current_page_item>a,
.main-navigation .current-menu-ancestor>a,
.main-navigation a.active {
    color: var(--primary-blue);
    background: rgba(0, 87, 184, 0.1);
    font-weight: 700;
}

/* ... existing button styles ... */

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 992px) {
    .site-header {
        width: 100%;
        top: 0;
        border-radius: 0;
        padding: 10px 20px;
    }

    .main-navigation,
    .header-actions {
        display: none;
        /* Hidden by default on mobile, toggled via JS */
    }

    .mobile-menu-toggle {
        display: block;
        margin-left: auto;
    }

    /* Mobile Menu Active State (when toggled via JS) */
    .site-header.mobile-open .main-navigation {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        padding: 20px;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    }

    .site-header.mobile-open .header-actions {
        display: flex;
        flex-direction: column;
        width: 100%;
        margin-top: 10px;
    }

    .site-header.mobile-open .main-navigation ul {
        flex-direction: column;
        width: 100%;
        gap: 10px;
    }
}

@media (max-width: 768px) {
    .hero {
        margin-top: 0;
        /* Header is sticky/fixed top 0 on mobile now */
        padding: 150px 0 80px;
        min-height: auto;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    /* Ensure horizontal blocks wrap on mobile */
    .features-grid.text-center {
        flex-direction: column !important;
    }
}

/* Restoring missing Header Styles */
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
}

.header-actions .btn {
    padding: 8px 24px;
    font-size: 0.9rem;
    border-radius: 30px;
    white-space: nowrap;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--darker-gray);
    cursor: pointer;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(0, 87, 184, 0.9), rgba(0, 61, 130, 0.85)), url('images/hero-bg.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--white);
    overflow: hidden;
    margin-top: 0;
    padding-top: 120px;
}

.hero::before {
    content: none;
    /* Removed the SVG pattern */
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 650px;
}

.hero h1 {
    color: var(--white);
    margin-bottom: var(--spacing-lg);
    animation: fadeInUp 0.8s ease-out;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    line-height: 1.1;
}

.hero p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: var(--spacing-xl);
    animation: fadeInUp 0.8s ease-out 0.2s both;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-md);
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero-buttons .btn {
    padding: 0.875rem 2rem;
    font-size: 1rem;
}

/* ============================================
   SERVICE CARDS (Reference Image Style)
   ============================================ */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--spacing-xl);
    margin: var(--spacing-xl) 0;
}

.service-card {
    background: var(--white);
    border: 1px solid var(--medium-gray);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    text-align: center;
    transition: all var(--transition-base);
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-blue);
}

.service-image {
    width: 100%;
    height: 200px;
    margin-bottom: var(--spacing-md);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

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

.service-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
    color: var(--black);
}

.service-card .service-excerpt {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--dark-gray);
    margin-bottom: var(--spacing-lg);
    flex-grow: 1;
}

.service-card .btn {
    align-self: center;
    padding: 12px 28px;
    font-size: 0.95rem;
    border-radius: var(--radius-full);
}


.service-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    color: var(--primary-blue);
}


/* ============================================
   WHY CHOOSE SECTON
   ============================================ */
.feature-item {
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.feature-icon-circle {
    width: 80px;
    height: 80px;
    background: rgba(0, 87, 184, 0.05);
    color: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin-bottom: var(--spacing-md);
}

.feature-item h3 {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-sm);
}

.feature-item p {
    font-size: 0.95rem;
    max-width: 300px;
    margin: 0 auto;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: var(--spacing-md);
}

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

.form-control {
    width: 100%;
    padding: 0.875rem 1.25rem;
    font-size: 1rem;
    font-family: var(--font-primary);
    border: 2px solid var(--medium-gray);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    background: var(--white);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0, 87, 184, 0.1);
}

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

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: var(--black);
    color: var(--white);
    padding: var(--spacing-3xl) 0 var(--spacing-lg);
}

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

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

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: var(--spacing-sm);
}

.footer-section a {
    color: var(--medium-gray);
    transition: color var(--transition-fast);
}

.footer-section a:hover {
    color: var(--accent-cyan);
}

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

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
    .main-navigation ul {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .hero {
        margin-top: 80px;
        padding: var(--spacing-xl) 0;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--white);
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    z-index: 9999;
    animation: slideInRight 0.3s ease-out;
}

.toast.success {
    border-left: 4px solid var(--secondary-green);
}

.toast.error {
    border-left: 4px solid var(--secondary-orange);
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}