/* =============================================
   Treo Solutions - Common Stylesheet
   ============================================= */

/* =============================================
   CSS Variables
   ============================================= */
:root {
    /* Primary Colors */
    --color-primary: #0066cc;
    --color-primary-dark: #0052a3;
    --color-primary-light: #ebf4ff;
    
    /* Accent Colors */
    --color-yellow: #d69e2e;
    --color-green: #48bb78;
    --color-green-dark: #38a169;
    --color-green-light: #68d391;
    
    /* Neutral Colors */
    --color-text: #2d3748;
    --color-text-light: #4a5568;
    --color-text-muted: #718096;
    --color-heading: #1a202c;
    --color-white: #ffffff;
    --color-bg-light: #f7fafc;
    --color-bg-alt: #edf2f7;
    --color-border: #e2e8f0;
    
    /* Dark Colors */
    --color-dark: #1a202c;
    --color-dark-blue: #1a365d;
    --color-dark-blue-light: #2c5282;
    
    /* Typography */
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    --font-family-mono: 'Monaco', 'Menlo', monospace;
    
    /* Spacing */
    --section-padding: 5rem 5%;
    --container-max-width: 1200px;
    
    /* Transitions */
    --transition-fast: 0.2s;
    --transition-normal: 0.3s;
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 12px;
    --radius-full: 50%;
}

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

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--color-text);
    background: var(--color-white);
}

/* =============================================
   Header & Navigation
   ============================================= */
header {
    background: var(--color-white);
    padding: 1.5rem 5%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    max-width: var(--container-max-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--color-text);
    font-weight: 500;
    transition: color var(--transition-normal);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--color-primary);
}

/* =============================================
   Buttons
   ============================================= */
.cta-button {
    background: var(--color-primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 600;
    transition: background var(--transition-normal), transform var(--transition-fast);
    display: inline-block;
}

.cta-button:hover {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
}

.cta-button.secondary {
    background: transparent;
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
}

.cta-button.secondary:hover {
    background: var(--color-primary);
    color: white;
}

/* =============================================
   Section Dividers
   ============================================= */
.section-divider {
    position: relative;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.section-divider svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 60px;
}

.section-divider.flip {
    transform: rotate(180deg);
}

/* =============================================
   Decorative Dot Elements
   ============================================= */

/* Dot Cluster - Small decorative dot group */
.dot-cluster {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 1rem;
}

.dot-cluster .dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
}

.dot-cluster .dot-blue { background: var(--color-primary); }
.dot-cluster .dot-yellow { background: var(--color-yellow); }
.dot-cluster .dot-green { background: var(--color-green); }

.dot-cluster.light .dot-blue { background: rgba(255,255,255,0.8); }
.dot-cluster.light .dot-yellow { background: var(--color-yellow); }
.dot-cluster.light .dot-green { background: var(--color-green); }

/* Section Dots - Background decorative dots */
.section-dots {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.section-dots .dot {
    position: absolute;
    border-radius: var(--radius-full);
    opacity: 0.4;
}

/* Hero Dots */
.hero-dots {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.hero-dots .dot {
    position: absolute;
    border-radius: var(--radius-full);
    opacity: 0.15;
}

.hero-dots .dot-1 { width: 80px; height: 80px; background: var(--color-green); top: 10%; right: 5%; }
.hero-dots .dot-2 { width: 40px; height: 40px; background: var(--color-yellow); top: 60%; right: 10%; }
.hero-dots .dot-3 { width: 60px; height: 60px; background: var(--color-white); bottom: 15%; right: 20%; }
.hero-dots .dot-4 { width: 30px; height: 30px; background: var(--color-green); top: 30%; left: 8%; }
.hero-dots .dot-5 { width: 50px; height: 50px; background: var(--color-yellow); bottom: 20%; left: 5%; }

/* CTA Section Dots */
.cta-section .section-dots .dot { opacity: 0.2; }
.cta-section .cta-dots-1 { width: 20px; height: 20px; background: #fff; top: 20%; left: 5%; }
.cta-section .cta-dots-2 { width: 14px; height: 14px; background: var(--color-yellow); top: 30%; left: 8%; }
.cta-section .cta-dots-3 { width: 10px; height: 10px; background: var(--color-green); top: 25%; left: 12%; }
.cta-section .cta-dots-4 { width: 16px; height: 16px; background: #fff; top: 60%; right: 6%; }
.cta-section .cta-dots-5 { width: 12px; height: 12px; background: var(--color-yellow); top: 70%; right: 10%; }
.cta-section .cta-dots-6 { width: 8px; height: 8px; background: var(--color-green); top: 50%; right: 14%; }

/* =============================================
   Page Hero Section
   ============================================= */
.page-hero {
    background: linear-gradient(135deg, var(--color-dark-blue) 0%, var(--color-dark-blue-light) 100%);
    color: white;
    padding: 5rem 5% 6rem;
    position: relative;
    overflow: hidden;
}

.page-hero-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.breadcrumb {
    margin-bottom: 1rem;
    opacity: 0.8;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.page-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.page-hero .subtitle {
    font-size: 1.25rem;
    opacity: 0.9;
    max-width: 700px;
}

.hero-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

/* =============================================
   Content Sections
   ============================================= */
.content-section {
    padding: var(--section-padding);
    position: relative;
}

.content-section.alt {
    background: var(--color-bg-light);
}

.section-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.25rem;
    color: var(--color-heading);
    margin-bottom: 1rem;
}

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

/* =============================================
   Service Cards
   ============================================= */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.service-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--color-primary-light) 0%, #dbeafe 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    font-size: 1.75rem;
}

.service-card h3 {
    font-size: 1.25rem;
    color: var(--color-heading);
    margin-bottom: 0.75rem;
}

.service-card p {
    color: var(--color-text-light);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.service-card ul {
    list-style: none;
}

.service-card li {
    padding: 0.35rem 0;
    padding-left: 1.25rem;
    position: relative;
    color: var(--color-text-light);
    font-size: 0.9rem;
}

.service-card li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--color-green-dark);
    font-weight: bold;
}

/* =============================================
   Benefit/Why Cards
   ============================================= */
.benefits-grid,
.why-us-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.benefit-card,
.why-card {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.benefit-card:hover,
.why-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.benefit-icon,
.why-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--color-primary-light) 0%, #dbeafe 100%);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    font-size: 2rem;
}

.benefit-card h3,
.why-card h3 {
    font-size: 1.25rem;
    color: var(--color-heading);
    margin-bottom: 0.75rem;
}

.benefit-card p,
.why-card p {
    color: var(--color-text-light);
}

/* =============================================
   CTA Section
   ============================================= */
.cta-section {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: white;
    padding: var(--section-padding);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-content {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.cta-section .cta-button {
    background: white;
    color: var(--color-primary);
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.cta-section .cta-button:hover {
    background: var(--color-bg-light);
}

/* =============================================
   Footer
   ============================================= */
footer {
    background: var(--color-dark);
    color: white;
    padding: 4rem 5% 2rem;
}

.footer-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
}

.footer-section h4 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: white;
}

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

.footer-section ul li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: #a0aec0;
    text-decoration: none;
    transition: color var(--transition-normal);
}

.footer-section a:hover {
    color: white;
}

.footer-section p {
    color: #a0aec0;
    line-height: 1.8;
}

.footer-bottom {
    max-width: var(--container-max-width);
    margin: 3rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid #2d3748;
    text-align: center;
    color: var(--color-text-muted);
}

/* =============================================
   Industry Cards
   ============================================= */
.industries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.industry-card {
    background: var(--color-bg-light);
    padding: 1.75rem 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    text-decoration: none;
    color: var(--color-text);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
    border: 1px solid var(--color-border);
}

.industry-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: var(--color-primary);
}

.industry-card .industry-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--color-primary-light) 0%, #dbeafe 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.5rem;
}

.industry-card h3 {
    font-size: 1rem;
    color: var(--color-heading);
}

/* =============================================
   Testimonials
   ============================================= */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.testimonial-card {
    background: var(--color-bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 1rem;
    left: 1.5rem;
    font-size: 4rem;
    color: var(--color-primary);
    opacity: 0.15;
    font-family: Georgia, serif;
    line-height: 1;
}

.testimonial-text {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    line-height: 1.7;
    position: relative;
    z-index: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    color: white;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.author-info h4 {
    color: var(--color-heading);
    font-size: 1rem;
}

.author-info p {
    color: var(--color-text-muted);
    font-size: 0.875rem;
}

/* =============================================
   Challenge Cards (Industry Pages)
   ============================================= */
.challenge-card {
    background: linear-gradient(135deg, #fffaf0 0%, #fef3c7 100%);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--color-yellow);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.challenge-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.challenge-card h4 {
    color: var(--color-heading);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.challenge-card p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

/* =============================================
   Use Case Cards
   ============================================= */
.use-cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.use-case-card {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--color-primary);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.use-case-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.use-case-card h3 {
    font-size: 1.1rem;
    color: var(--color-heading);
    margin-bottom: 0.5rem;
}

.use-case-card p {
    color: var(--color-text-light);
    font-size: 0.9rem;
}

/* =============================================
   System Cards (Dark Section)
   ============================================= */
.systems-section {
    background: linear-gradient(135deg, var(--color-dark) 0%, #2d3748 100%);
    color: white;
    padding: var(--section-padding);
    position: relative;
    overflow: hidden;
}

.systems-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.systems-section h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 1rem;
}

.systems-section .section-subtitle {
    text-align: center;
    opacity: 0.9;
    margin-bottom: 3rem;
}

.systems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.system-card {
    background: rgba(255,255,255,0.1);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    transition: transform var(--transition-normal), background var(--transition-normal);
}

.system-card:hover {
    transform: translateY(-3px);
    background: rgba(255,255,255,0.15);
}

.system-card h4 {
    margin-bottom: 0.5rem;
}

.system-card p {
    opacity: 0.8;
    font-size: 0.9rem;
}

/* System section dots */
.systems-section .section-dots .dot { opacity: 0.1; }
.systems-section .section-dots .dot-1 { width: 100px; height: 100px; background: var(--color-green); top: -30px; left: 5%; }
.systems-section .section-dots .dot-2 { width: 60px; height: 60px; background: var(--color-yellow); bottom: 10%; left: 10%; }
.systems-section .section-dots .dot-3 { width: 80px; height: 80px; background: var(--color-white); top: 20%; right: 8%; }

/* =============================================
   Understanding/Intro Grid (Industry Pages)
   ============================================= */
.understanding,
.intro-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.understanding-text h2,
.intro-text h2 {
    font-size: 2rem;
    color: var(--color-heading);
    margin-bottom: 1.5rem;
}

.understanding-text p,
.intro-text p {
    color: var(--color-text-light);
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

.understanding-points {
    margin-top: 2rem;
    list-style: none;
    padding: 0;
}

.understanding-points li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    color: var(--color-text-light);
    padding-left: 1.5rem;
    position: relative;
}

.understanding-points li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--color-green-dark);
    font-weight: bold;
}

/* =============================================
   Stats Cards
   ============================================= */
.intro-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.stat-card {
    background: var(--color-bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
    border: 1px solid var(--color-border);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.stat-card .number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1;
}

.stat-card .label {
    color: var(--color-text-light);
    margin-top: 0.5rem;
}

/* =============================================
   Platform Names Box
   ============================================= */
.platform-names {
    background: linear-gradient(135deg, var(--color-primary-light) 0%, #dbeafe 100%);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin-top: 1.5rem;
}

.platform-names h4 {
    color: var(--color-heading);
    margin-bottom: 0.75rem;
}

.platform-names ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.platform-names li {
    background: white;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

/* =============================================
   Why IBM i / Dark Section Cards
   ============================================= */
.why-ibmi {
    background: linear-gradient(135deg, var(--color-dark-blue) 0%, var(--color-dark-blue-light) 100%);
    color: white;
    padding: var(--section-padding);
    position: relative;
    overflow: hidden;
}

.why-ibmi-content {
    max-width: var(--container-max-width);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.why-ibmi h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 1rem;
}

.why-ibmi .section-subtitle {
    text-align: center;
    opacity: 0.9;
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.why-grid .why-card {
    text-align: center;
    padding: 1.5rem;
    background: transparent;
    border: none;
}

.why-grid .why-card .icon {
    width: 70px;
    height: 70px;
    background: rgba(255,255,255,0.15);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2rem;
}

.why-grid .why-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: white;
}

.why-grid .why-card p {
    opacity: 0.9;
    font-size: 0.95rem;
    color: white;
}

/* Why IBM i section dots */
.why-ibmi .section-dots .dot-1 { width: 100px; height: 100px; background: var(--color-green); top: -30px; left: 5%; opacity: 0.15; }
.why-ibmi .section-dots .dot-2 { width: 60px; height: 60px; background: var(--color-yellow); bottom: 10%; left: 10%; opacity: 0.15; }
.why-ibmi .section-dots .dot-3 { width: 80px; height: 80px; background: var(--color-white); top: 20%; right: 8%; opacity: 0.15; }

/* =============================================
   Responsive Styles
   ============================================= */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .page-hero h1 {
        font-size: 2rem;
    }

    .understanding,
    .intro-grid {
        grid-template-columns: 1fr;
    }

    .intro-stats {
        grid-template-columns: 1fr;
    }

    .section-divider svg {
        height: 40px;
    }

    .cta-section h2 {
        font-size: 2rem;
    }

    .section-header h2 {
        font-size: 1.75rem;
    }
}
