/**
 * Main Stylesheet for SS Infotech E-Commerce Website
 * Author: The Dynamic Developer
 * Version: 2.0
 */

/* ========================================
   ROOT VARIABLES & THEME COLORS
======================================== */
:root {
    /* Modern IT Company Color Palette */
    --primary-color: #0A47A3;
    /* Deep Blue */
    --accent-color: #1E90FF;
    /* Bright Blue */
    --secondary-color: #F2F6FC;
    /* Soft Light Gray/Blue */

    /* Neutral Colors */
    --dark-bg: #0A47A3;
    --dark-grey: #333333;
    --light-grey: #F2F6FC;
    --white: #FFFFFF;
    --black: #000000;

    /* Text Colors */
    --text-primary: #0A47A3;
    /* Headlines - Deep Blue */
    --text-secondary: #6B6B6B;
    /* Subtext - Medium Gray */
    --text-body: #333333;
    /* Body - Dark Gray */
    --text-dark: #333333;
    --text-muted: #8A8A8A;
    --text-light: #FFFFFF;

    /* Background Colors */
    --bg-primary: #FFFFFF;
    --bg-secondary: #F2F6FC;
    --bg-card: #FFFFFF;

    /* Status Colors */
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #1E90FF;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #0A47A3 0%, #1E90FF 100%);
    --gradient-secondary: linear-gradient(135deg, #1E90FF 0%, #0A47A3 100%);

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(10, 71, 163, 0.08);
    --shadow-md: 0 4px 8px rgba(10, 71, 163, 0.12);
    --shadow-lg: 0 8px 16px rgba(10, 71, 163, 0.15);
    --shadow-xl: 0 12px 24px rgba(10, 71, 163, 0.18);

    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-base: 300ms ease-in-out;
    --transition-slow: 500ms ease-in-out;

    /* Typography */
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Nunito', sans-serif;
}

/* ========================================
   GLOBAL RESET & BASE STYLES
======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    background-color: var(--bg-primary);
    color: var(--text-body);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Dark sections */
.dark-section,
.main-footer {
    background-color: var(--dark-bg);
    color: var(--text-primary);
}

/* ========================================
   TYPOGRAPHY
======================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-primary);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
}

h5 {
    font-size: clamp(1.125rem, 2vw, 1.5rem);
}

h6 {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
}

p {
    font-family: var(--font-secondary);
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition-base);
}

a:hover {
    color: var(--accent-teal);
    text-decoration: none;
}

/* ========================================
   HEADER & NAVIGATION
======================================== */
.main-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.navbar {
    padding: var(--spacing-md) 0;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color) !important;
    transition: var(--transition-base);
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.logo-img {
    height: 50px;
    width: auto;
    object-fit: contain;
    transition: var(--transition-base);
}

.brand-name {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
}

.nav-link {
    color: var(--text-dark) !important;
    font-weight: 500;
    padding: var(--spacing-sm) var(--spacing-md) !important;
    margin: 0 var(--spacing-xs);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color) !important;
    background-color: rgba(0, 174, 239, 0.1);
}

.nav-link i {
    font-size: 1rem;
    margin-right: var(--spacing-xs);
}

/* Cart Badge */
.nav-link .badge {
    font-size: 0.65rem;
    padding: 0.25em 0.5em;
}

/* ========================================
   MAIN CONTENT
======================================== */
.main-content {
    min-height: calc(100vh - 400px);
    padding: var(--spacing-2xl) 0;
}

.container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* ========================================
   BUTTONS
======================================== */
.btn {
    font-family: var(--font-primary);
    font-weight: 600;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
}

.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);
    background: var(--gradient-secondary);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--secondary-color);
    color: var(--text-dark);
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-warning {
    background: var(--warning);
    color: var(--white);
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 0.75rem 2rem;
    font-size: 1.125rem;
}

/* ========================================
   CARDS
======================================== */
.card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    transition: var(--transition-base);
    box-shadow: var(--shadow-md);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-color);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
}

.card-text {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ========================================
   FORMS
======================================== */
.form-control,
.form-select {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
    font-family: var(--font-secondary);
}

.form-control:focus,
.form-select:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(0, 174, 239, 0.25);
    color: var(--text-primary);
    outline: none;
}

.form-control::placeholder {
    color: var(--text-muted);
}

.form-label {
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

/* ========================================
   FOOTER
======================================== */
.main-footer {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: var(--text-secondary);
    margin-top: var(--spacing-2xl);
}

.footer-logo {
    height: 40px;
    width: auto;
    filter: brightness(0) invert(1);
}

.footer-heading {
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: var(--spacing-md);
    position: relative;
    padding-bottom: var(--spacing-sm);
}

.footer-heading::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-teal));
    border-radius: var(--radius-full);
}

.footer-text {
    color: var(--text-secondary);
    line-height: 1.8;
}

.footer-links li {
    margin-bottom: var(--spacing-sm);
}

.footer-links a {
    color: var(--text-secondary);
    transition: var(--transition-base);
    display: inline-flex;
    align-items: center;
}

.footer-links a:hover {
    color: var(--primary-color);
    transform: translateX(5px);
}

.footer-contact li {
    margin-bottom: var(--spacing-md);
    display: flex;
    align-items: flex-start;
    color: var(--text-secondary);
}

.footer-contact i {
    color: var(--primary-color);
    margin-top: 0.25rem;
    flex-shrink: 0;
}

.footer-contact a {
    color: var(--text-secondary);
}

.footer-contact a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: var(--spacing-md);
}

.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    transition: var(--transition-base);
}

.social-link:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-3px);
}

.footer-divider {
    border-color: rgba(255, 255, 255, 0.1);
}

.footer-copyright,
.footer-developer {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.footer-developer strong {
    color: var(--primary-color);
    font-weight: 700;
}

/* ========================================
   BACK TO TOP BUTTON
======================================== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-teal));
    color: var(--white);
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: var(--transition-base);
    z-index: 999;
}

.back-to-top.show {
    display: flex;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

/* ========================================
   UTILITY CLASSES
======================================== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-teal));
}

.shadow-sm {
    box-shadow: var(--shadow-sm);
}

.shadow-md {
    box-shadow: var(--shadow-md);
}

.shadow-lg {
    box-shadow: var(--shadow-lg);
}

.shadow-xl {
    box-shadow: var(--shadow-xl);
}

/* ========================================
   ANIMATIONS
======================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}