/* Avenir Next World Font Definitions */
@font-face {
    font-family: 'Avenir Next World';
    src: url('../fonts/AvenirNextWorld-Demi.woff2') format('woff2'),
         url('../fonts/AvenirNextWorld-Demi.woff') format('woff'),
         url('../fonts/AvenirNextWorld-Demi.ttf') format('truetype'),
         url('../fonts/AvenirNextWorld-Demi.eot') format('embedded-opentype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

/* CSS Variables for Font Families */
:root {
    --font-family-primary: 'Avenir Next World', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-family-primary-arabic: 'Avenir Next World', 'Cairo', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-family-secondary: 'Avenir Next World', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-family-secondary-arabic: 'Avenir Next World', 'Cairo', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Typography Classes */
.font-primary {
    font-family: var(--font-family-primary) !important;
}

.font-primary-arabic {
    font-family: var(--font-family-primary-arabic) !important;
}

.font-secondary {
    font-family: var(--font-family-secondary) !important;
}

.font-secondary-arabic {
    font-family: var(--font-family-secondary-arabic) !important;
}

/* Avenir Next World specific classes */
.avenir-next-world {
    font-family: 'Avenir Next World', sans-serif !important;
}

.avenir-next-world-arabic {
    font-family: 'Avenir Next World', 'Cairo', sans-serif !important;
}

/* Font weight utilities */
.font-demi {
    font-weight: 600 !important;
}

/* Responsive typography */
@media (max-width: 768px) {
    .avenir-next-world {
        font-size: 0.95em;
    }
}

/* Fonts - Footer Section */

/* Footer Font Loading */
@font-face {
    font-family: 'FooterFont';
    src: url('../fonts/AvenirNextWorld-Demi.woff2') format('woff2'),
         url('../fonts/AvenirNextWorld-Demi.woff') format('woff'),
         url('../fonts/AvenirNextWorld-Demi.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'FooterTextFont';
    src: url('../fonts/AvenirNextWorld-Demi.woff2') format('woff2'),
         url('../fonts/AvenirNextWorld-Demi.woff') format('woff'),
         url('../fonts/AvenirNextWorld-Demi.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* Footer Font Variables */
.store-footer {
    --footer-primary-font: 'FooterFont', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --footer-secondary-font: 'FooterTextFont', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --footer-fallback-font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Footer Font Applications */
.store-footer h5,
.store-footer h6 {
    font-family: var(--footer-primary-font);
    font-weight: 600;
    font-feature-settings: 'liga' 1, 'kern' 1;
    text-rendering: optimizeLegibility;
}

.store-footer p,
.store-footer div,
.store-footer span {
    font-family: var(--footer-secondary-font);
    font-weight: 400;
    font-feature-settings: 'liga' 1, 'kern' 1;
    text-rendering: optimizeLegibility;
}

.store-footer a {
    font-family: var(--footer-secondary-font);
    font-weight: 500;
    font-feature-settings: 'liga' 1, 'kern' 1;
    text-rendering: optimizeLegibility;
}

/* Footer Font Loading States */
.store-footer.font-loading h5,
.store-footer.font-loading h6,
.store-footer.font-loading p,
.store-footer.font-loading a {
    font-family: var(--footer-fallback-font);
}

.store-footer.font-loaded h5,
.store-footer.font-loaded h6 {
    font-family: var(--footer-primary-font);
}

.store-footer.font-loaded p,
.store-footer.font-loaded div,
.store-footer.font-loaded span,
.store-footer.font-loaded a {
    font-family: var(--footer-secondary-font);
}

/* Footer Font Optimization */
.store-footer {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

.store-footer h5,
.store-footer h6 {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

.store-footer p,
.store-footer a {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Footer Font Sizes */
.store-footer {
    font-size: 16px; /* Base font size */
    line-height: 1.6;
}

.store-footer h5 {
    font-size: 1.1rem;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.store-footer h6 {
    font-size: 1rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.store-footer p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.store-footer a {
    font-size: 0.9rem;
    line-height: 1.4;
}

.store-footer small {
    font-size: 0.8rem;
    line-height: 1.5;
}

/* Footer Font Weights */
.store-footer h5,
.store-footer h6 {
    font-weight: 600;
}

.store-footer p,
.store-footer div {
    font-weight: 400;
}

.store-footer a {
    font-weight: 500;
}

.store-footer strong,
.store-footer b {
    font-weight: 600;
}

/* Footer Font Spacing */
.store-footer h5,
.store-footer h6 {
    letter-spacing: 0.02em;
}

.store-footer p,
.store-footer div {
    letter-spacing: 0.01em;
}

.store-footer a {
    letter-spacing: 0.005em;
}

/* Footer Font Responsive */
@media (max-width: 768px) {
    .store-footer {
        font-size: 15px;
    }
    
    .store-footer h5 {
        font-size: 1rem;
    }
    
    .store-footer h6 {
        font-size: 0.95rem;
    }
    
    .store-footer p {
        font-size: 0.9rem;
    }
    
    .store-footer a {
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .store-footer {
        font-size: 14px;
    }
    
    .store-footer h5 {
        font-size: 0.95rem;
    }
    
    .store-footer h6 {
        font-size: 0.9rem;
    }
    
    .store-footer p {
        font-size: 0.85rem;
    }
    
    .store-footer a {
        font-size: 0.8rem;
    }
}

/* Footer Font Print */
@media print {
    .store-footer {
        font-size: 12pt;
    }
    
    .store-footer h5 {
        font-size: 14pt;
    }
    
    .store-footer h6 {
        font-size: 13pt;
    }
    
    .store-footer p {
        font-size: 11pt;
    }
    
    .store-footer a {
        font-size: 10pt;
    }
}

/* Footer Font High Contrast */
@media (prefers-contrast: high) {
    .store-footer h5,
    .store-footer h6 {
        font-weight: 700;
    }
    
    .store-footer p,
    .store-footer div {
        font-weight: 500;
    }
    
    .store-footer a {
        font-weight: 600;
    }
}

/* Footer Font Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .store-footer * {
        transition: none !important;
        animation: none !important;
    }
}
