/*
=============================================
  MAIN.CSS - Core Styles & Utilities
=============================================
*/

/* ================================
   RESET & BASE
   ================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: var(--leading-normal);
    color: var(--dark);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    max-width: 100vw;
}

/* Remove default styles for interactive elements */
button,
input,
select,
textarea {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
}

a {
    color: inherit;
    text-decoration: none;
}

img,
video,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

ul,
ol {
    list-style: none;
}

/* ================================
   TYPOGRAPHY
   ================================ */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    color: var(--dark);
}

h1 {
    font-size: var(--text-hero);
}

h2 {
    font-size: var(--text-4xl);
}

h3 {
    font-size: var(--text-3xl);
}

h4 {
    font-size: var(--text-2xl);
}

h5 {
    font-size: var(--text-xl);
}

h6 {
    font-size: var(--text-lg);
}

p {
    margin-bottom: var(--space-md);
    color: var(--gray-600);
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ================================
   LAYOUT UTILITIES
   ================================ */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--section-padding-x);
}

.container-narrow {
    max-width: var(--container-narrow);
}

.container-wide {
    max-width: var(--container-wide);
}

/* Sections */
.section {
    padding: var(--section-padding-y) 0;
    position: relative;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto var(--space-3xl);
}

.section-header h2 {
    margin-bottom: var(--space-md);
}

.section-header p {
    font-size: var(--text-lg);
}

/* Backgrounds */
.bg-dark {
    background-color: var(--dark);
    color: var(--white);
}

.bg-dark h1,
.bg-dark h2,
.bg-dark h3,
.bg-dark h4,
.bg-dark h5,
.bg-dark h6 {
    color: var(--white);
}

.bg-dark p {
    color: var(--gray-400);
}

.bg-light {
    background-color: var(--gray-100);
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
}

/* ================================
   FLEXBOX & GRID UTILITIES
   ================================ */
.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-sm {
    gap: var(--space-sm);
}

.gap-md {
    gap: var(--space-md);
}

.gap-lg {
    gap: var(--space-lg);
}

.gap-xl {
    gap: var(--space-xl);
}

.gap-2xl {
    gap: var(--space-2xl);
}

/* Grid */
.grid {
    display: grid;
}

.grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-cols-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1024px) {
    .grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-cols-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {

    .grid-cols-2,
    .grid-cols-3,
    .grid-cols-4 {
        grid-template-columns: 1fr;
    }
}

/* ================================
   BUTTONS - Premium 3D Style
   ================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-xl);
    font-size: var(--text-base);
    font-weight: var(--font-bold);
    letter-spacing: 0.02em;
    border-radius: var(--radius-lg);
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
    text-decoration: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(180deg,
            hsl(221, 83%, 58%) 0%,
            hsl(221, 83%, 48%) 50%,
            hsl(224, 76%, 42%) 100%);
    color: var(--white);
    border: 1px solid hsl(221, 83%, 62%);
    box-shadow:
        0 1px 0 0 hsla(221, 100%, 80%, 0.4) inset,
        0 -2px 4px 0 hsla(224, 76%, 30%, 0.4) inset,
        0 4px 12px -2px hsla(221, 83%, 40%, 0.5),
        0 2px 4px -1px rgba(0, 0, 0, 0.2);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    background: linear-gradient(180deg,
            hsl(221, 83%, 62%) 0%,
            hsl(221, 83%, 52%) 50%,
            hsl(224, 76%, 46%) 100%);
    box-shadow:
        0 1px 0 0 hsla(221, 100%, 80%, 0.5) inset,
        0 -2px 4px 0 hsla(224, 76%, 30%, 0.4) inset,
        0 8px 20px -4px hsla(221, 83%, 40%, 0.6),
        0 4px 8px -2px rgba(0, 0, 0, 0.25);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow:
        0 1px 0 0 hsla(221, 100%, 80%, 0.2) inset,
        0 -1px 2px 0 hsla(224, 76%, 30%, 0.5) inset,
        0 2px 4px -1px hsla(221, 83%, 40%, 0.4);
}

.btn-secondary {
    background: linear-gradient(180deg,
            hsl(38, 92%, 60%) 0%,
            hsl(38, 92%, 50%) 50%,
            hsl(28, 80%, 48%) 100%);
    color: var(--dark);
    border: 1px solid hsl(38, 92%, 65%);
    box-shadow:
        0 1px 0 0 hsla(38, 100%, 75%, 0.5) inset,
        0 -2px 4px 0 hsla(28, 80%, 35%, 0.3) inset,
        0 4px 12px -2px hsla(38, 92%, 45%, 0.4),
        0 2px 4px -1px rgba(0, 0, 0, 0.15);
    text-shadow: 0 1px 0 hsla(38, 100%, 75%, 0.5);
}

.btn-secondary:hover {
    transform: translateY(-3px);
    background: linear-gradient(180deg,
            hsl(38, 92%, 65%) 0%,
            hsl(38, 92%, 55%) 50%,
            hsl(28, 80%, 52%) 100%);
    box-shadow:
        0 1px 0 0 hsla(38, 100%, 80%, 0.6) inset,
        0 -2px 4px 0 hsla(28, 80%, 35%, 0.3) inset,
        0 8px 20px -4px hsla(38, 92%, 45%, 0.5),
        0 4px 8px -2px rgba(0, 0, 0, 0.2);
}

.btn-secondary:active {
    transform: translateY(0);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}

.btn-outline:hover {
    background: var(--white);
    color: var(--dark);
    box-shadow:
        0 4px 12px rgba(255, 255, 255, 0.3),
        0 2px 4px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--primary);
    border: 1px solid transparent;
}

.btn-ghost:hover {
    background: var(--gray-100);
    border-color: var(--gray-200);
}

.btn-lg {
    padding: var(--space-lg) var(--space-2xl);
    font-size: var(--text-lg);
    border-radius: var(--radius-xl);
}

.btn-sm {
    padding: var(--space-sm) var(--space-md);
    font-size: var(--text-sm);
    border-radius: var(--radius-md);
}

/* ================================
   CARDS
   ================================ */
.card {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    border: 1px solid var(--gray-200);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: var(--gray-300);
}

.card-glass {
    background: var(--glass-bg-light);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
}

.card-dark {
    background: var(--dark-soft);
    color: var(--white);
}

/* ================================
   FORM ELEMENTS
   ================================ */
.form-group {
    margin-bottom: var(--space-lg);
}

.form-label {
    display: block;
    margin-bottom: var(--space-sm);
    font-weight: var(--font-medium);
    color: var(--dark);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: var(--space-md) var(--space-lg);
    font-size: var(--text-base);
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-lg);
    background: var(--white);
    transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.form-textarea {
    min-height: 150px;
    resize: vertical;
}

/* ================================
   NAVIGATION
   ================================ */
.nav-link {
    color: var(--gray-600);
    font-weight: var(--font-medium);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.nav-link:hover {
    color: var(--primary);
    background: var(--gray-100);
}

/* ================================
   ICONS - With proper centering
   ================================ */
.icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5em;
    height: 1.5em;
}

.icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: var(--radius-full);
    background: linear-gradient(180deg,
            hsl(221, 83%, 58%) 0%,
            hsl(224, 76%, 42%) 100%);
    color: var(--white);
    border: 1px solid hsl(221, 83%, 62%);
    box-shadow:
        0 1px 0 0 hsla(221, 100%, 80%, 0.3) inset,
        0 4px 8px -2px hsla(221, 83%, 40%, 0.4);
    font-size: 1.5rem;
    line-height: 1;
}

.icon-lg {
    width: 4.5rem;
    height: 4.5rem;
    font-size: 1.75rem;
}

/* ================================
   BADGES & TAGS
   ================================ */
.badge {
    display: inline-flex;
    align-items: center;
    padding: var(--space-xs) var(--space-md);
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    border-radius: var(--radius-full);
    background: var(--gray-100);
    color: var(--gray-700);
}

.badge-primary {
    background: var(--primary);
    color: var(--white);
}

/* ================================
   UTILITY CLASSES
   ================================ */
.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.hidden {
    display: none !important;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Spacing */
.mt-auto {
    margin-top: auto;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-md {
    margin-bottom: var(--space-md);
}

.mb-lg {
    margin-bottom: var(--space-lg);
}

.mb-xl {
    margin-bottom: var(--space-xl);
}

/* ================================
   RESPONSIVE UTILITIES
   ================================ */
@media (max-width: 768px) {
    .hide-mobile {
        display: none !important;
    }
}

@media (min-width: 769px) {
    .hide-desktop {
        display: none !important;
    }
}

/* ================================
   WORDPRESS OVERRIDES
   ================================ */
/* Override any parent theme styles that conflict */
.wp-site-blocks {
    padding: 0;
}

.entry-content>* {
    max-width: none;
}