/*
Theme Name: iBase IT Services Theme
Theme URI: https://www.ibasesolutions.in
Author: iBase IT Digital Solutions
Author URI: https://www.ibasesolutions.in
Description: A professional, modern WordPress theme designed specifically for Software IT Services companies. Features include custom post types for services and portfolio, responsive design, theme customizer support, and SEO-friendly structure.
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: ibase-it
Tags: business, corporate, it-services, technology, professional, responsive, custom-post-types

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned with others.
*/

/* ==========================================================================
   Base Styles
   ========================================================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #3b82f6;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --white: #ffffff;
    --border-color: #e5e7eb;
    --success: #10b981;
    --error: #ef4444;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

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: 1rem;
    color: var(--text-light);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

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

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

/* ==========================================================================
   Layout
   ========================================================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    flex: 1;
    padding: 0 15px;
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
    background-color: var(--white);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.site-branding {
    display: flex;
    align-items: center;
}

.site-title {
    font-size: 1.5rem;
    margin: 0;
}

.site-title a {
    color: var(--text-dark);
    text-decoration: none;
}

.custom-logo-link {
    display: block;
    max-width: 200px;
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.main-navigation {
    display: flex;
    align-items: center;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    margin: 0;
    padding: 0;
}

.main-navigation li {
    margin: 0 1rem;
    position: relative;
}

.main-navigation a {
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 0;
    display: block;
}

.main-navigation a:hover {
    color: var(--primary-color);
}

.main-navigation .current-menu-item > a {
    color: var(--primary-color);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-radius: 4px;
    font-weight: 600;
}

.menu-toggle:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 6rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" 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.5;
}

.hero-content h1 {
    color: var(--white);
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.hero-content p {
    color: rgba(255,255,255,0.9);
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: 6px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 1rem;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

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

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

/* ==========================================================================
   Sections
   ========================================================================== */

.section {
    padding: 5rem 0;
}

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

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

.section-title p {
    font-size: 1.125rem;
    max-width: 700px;
    margin: 0 auto;
}

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

/* ==========================================================================
   Services
   ========================================================================== */

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    text-align: center;
}

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

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

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

/* ==========================================================================
   Portfolio/Projects
   ========================================================================== */

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

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.portfolio-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: var(--white);
    padding: 2rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    transform: translateY(0);
}

/* ==========================================================================
   Blog
   ========================================================================== */

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

.blog-post {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.blog-post:hover {
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

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

.post-content {
    padding: 2rem;
}

.post-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--text-light);
}

.post-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.post-title a {
    color: var(--text-dark);
}

.post-title a:hover {
    color: var(--primary-color);
}

.post-excerpt {
    color: var(--text-light);
    margin-bottom: 1rem;
}

/* ==========================================================================
   Sidebar
   ========================================================================== */

.sidebar {
    padding-left: 2rem;
}

.widget {
    background-color: var(--bg-light);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.widget-title {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
}

.widget ul {
    list-style: none;
}

.widget li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.widget li:last-child {
    border-bottom: none;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background-color: var(--text-dark);
    color: var(--white);
    padding: 3rem 0 1rem;
}

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

.footer-widget h3 {
    color: var(--white);
    margin-bottom: 1rem;
}

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

.footer-widget li {
    margin-bottom: 0.5rem;
}

.footer-widget a {
    color: rgba(255,255,255,0.8);
}

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

.site-info {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.7);
}

/* ==========================================================================
   Forms
   ========================================================================== */

.contact-form {
    max-width: 700px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
textarea,
select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
}

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

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    
    .site-header .container {
        flex-wrap: wrap;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .main-navigation {
        width: 100%;
        margin-top: 1rem;
    }
    
    .main-navigation ul {
        display: none;
        flex-direction: column;
        width: 100%;
    }
    
    .main-navigation.toggled ul {
        display: flex;
    }
    
    .main-navigation li {
        margin: 0;
        border-bottom: 1px solid var(--border-color);
    }
    
    .main-navigation a {
        padding: 1rem;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .services-grid,
    .portfolio-grid,
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        padding-left: 0;
        margin-top: 2rem;
    }
    
    .section {
        padding: 3rem 0;
    }
}

/* ==========================================================================
   Utilities
   ========================================================================== */

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

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 2rem; }

.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }

/* Accessibility */
.screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

/* Print Styles */
@media print {
    .no-print { display: none; }
}