/* Final Touches - Ensuring Perfect Design */

/* Perfect Alignment */
.store-header .row {
    align-items: center !important;
}

.store-navbar .navbar-nav {
    align-items: center !important;
}

/* Perfect Spacing */
.store-header {
    padding: 1.5rem 0 !important;
}

.store-navbar {
    padding: 0.75rem 0 !important;
}

.store-footer {
    padding: 3rem 0 2rem !important;
    margin-top: 4rem !important;
}

/* Perfect Typography */
.store-header h1 {
    line-height: 1.2 !important;
    margin: 0 !important;
}

.store-navbar .navbar-nav .nav-link {
    line-height: 1.4 !important;
    white-space: nowrap !important;
}

/* Perfect Icons */
.store-navbar .navbar-nav .nav-link i {
    vertical-align: middle !important;
    line-height: 1 !important;
}

.cart-icon, .user-menu {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Perfect Buttons */
.store-navbar .btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
}

.store-navbar .btn i {
    margin-right: 0.5rem !important;
}

/* Perfect Form Controls */
.store-navbar .form-control {
    height: auto !important;
    line-height: 1.5 !important;
}

/* Perfect Dropdowns */
.dropdown-menu {
    margin-top: 0.5rem !important;
    min-width: 200px !important;
}

.dropdown-item {
    white-space: nowrap !important;
}

/* Perfect Badges */
.cart-badge {
    line-height: 1 !important;
    text-align: center !important;
}

.currency-badge .badge {
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

/* Perfect Social Links */
.store-footer .social-links {
    display: flex !important;
    gap: 0.75rem !important;
    flex-wrap: wrap !important;
}

.store-footer .social-links a {
    flex-shrink: 0 !important;
}

/* Perfect Lists */
.store-footer ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.store-footer ul li {
    margin-bottom: 0.75rem !important;
}

.store-footer ul li:last-child {
    margin-bottom: 0 !important;
}

/* Perfect Links */
.store-footer ul li a {
    display: inline-block !important;
    text-decoration: none !important;
    transition: color 0.3s ease !important;
}

/* Perfect Responsive */
@media (max-width: 768px) {
    .store-header .row {
        text-align: center !important;
    }
    
    .store-header .col-md-6:last-child {
        margin-top: 1rem !important;
    }
    
    .store-navbar .navbar-nav {
        margin-bottom: 1rem !important;
    }
    
    .store-navbar .d-flex {
        justify-content: center !important;
        width: 100% !important;
    }
}

@media (max-width: 576px) {
    .store-header {
        padding: 1rem 0 !important;
    }
    
    .store-navbar {
        padding: 0.5rem 0 !important;
    }
    
    .store-footer {
        padding: 2rem 0 1.5rem !important;
        margin-top: 3rem !important;
    }
    
    .store-footer .row > div {
        margin-bottom: 2rem !important;
    }
    
    .store-footer .row > div:last-child {
        margin-bottom: 0 !important;
    }
}

/* Perfect RTL */
[dir="rtl"] .store-navbar .btn i {
    margin-right: 0 !important;
    margin-left: 0.5rem !important;
}

[dir="rtl"] .store-footer .social-links {
    justify-content: flex-start !important;
}

[dir="rtl"] .store-footer .social-links a {
    margin-right: 0 !important;
    margin-left: 0 !important;
}

/* Perfect Focus States */
.store-navbar .nav-link:focus,
.store-navbar .btn:focus,
.store-navbar .form-control:focus,
.cart-icon:focus,
.user-menu:focus {
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.2) !important;
}

/* Perfect Hover States */
.store-navbar .navbar-nav .nav-link:hover,
.store-navbar .btn:hover,
.cart-icon:hover,
.user-menu:hover {
    text-decoration: none !important;
}

/* Perfect Active States */
.store-navbar .navbar-nav .nav-link.active {
    position: relative !important;
}

.store-navbar .navbar-nav .nav-link.active::after {
    content: '' !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 60% !important;
    height: 2px !important;
    background: #007AFF !important;
    border-radius: 1px !important;
}

/* Perfect Loading States */
.store-navbar .btn:disabled,
.store-navbar .form-control:disabled {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}

/* Perfect Print */
@media print {
    .store-header,
    .store-navbar,
    .store-footer {
        background: white !important;
        color: black !important;
        box-shadow: none !important;
        border: 1px solid #ccc !important;
    }
    
    .store-navbar .navbar-nav .nav-link:hover,
    .store-navbar .btn:hover {
        background: none !important;
        color: black !important;
        transform: none !important;
        box-shadow: none !important;
    }
    
    .cart-badge,
    .announcement-bar {
        display: none !important;
    }
}

/* Perfect Accessibility */
@media (prefers-reduced-motion: reduce) {
    .store-navbar .navbar-nav .nav-link,
    .store-navbar .btn,
    .store-navbar .form-control,
    .cart-icon,
    .user-menu,
    .store-logo,
    .store-footer .social-links a,
    .dropdown-menu,
    .dropdown-item {
        transition: none !important;
        animation: none !important;
        transform: none !important;
    }
}

/* Perfect High Contrast */
@media (prefers-contrast: high) {
    .store-header,
    .store-navbar {
        border-bottom: 2px solid #000 !important;
    }
    
    .store-navbar .navbar-nav .nav-link:hover,
    .store-navbar .btn:hover {
        background: #000 !important;
        color: #fff !important;
    }
    
    .store-navbar .form-control:focus {
        border-color: #000 !important;
        box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.3) !important;
    }
}

/* Perfect Dark Mode */
@media (prefers-color-scheme: dark) {
    .store-header {
        background: rgba(0, 0, 0, 0.95) !important;
        color: #fff !important;
    }
    
    .store-navbar {
        background: rgba(0, 0, 0, 0.98) !important;
        color: #fff !important;
    }
    
    .store-footer {
        background: #1c1c1e !important;
        color: #fff !important;
    }
    
    .store-navbar .form-control {
        background: #1c1c1e !important;
        color: #fff !important;
        border-color: #38383a !important;
    }
    
    .store-navbar .form-control:focus {
        background: #2c2c2e !important;
        border-color: #007AFF !important;
    }
}

/* Perfect Performance */
.store-header,
.store-navbar,
.store-footer {
    will-change: transform !important;
    backface-visibility: hidden !important;
}

.store-navbar .navbar-nav .nav-link,
.store-navbar .btn,
.cart-icon,
.user-menu {
    will-change: transform, background-color !important;
}

/* Perfect Cross-Browser */
.store-header,
.store-navbar {
    -webkit-backdrop-filter: blur(20px) !important;
    backdrop-filter: blur(20px) !important;
}

.store-navbar .navbar-nav .nav-link {
    -webkit-transform: translateZ(0) !important;
    transform: translateZ(0) !important;
}

/* Perfect Mobile Touch */
@media (hover: none) and (pointer: coarse) {
    .store-navbar .navbar-nav .nav-link:hover,
    .store-navbar .btn:hover,
    .cart-icon:hover,
    .user-menu:hover {
        background: none !important;
        transform: none !important;
    }
    
    .store-navbar .navbar-nav .nav-link:active,
    .store-navbar .btn:active,
    .cart-icon:active,
    .user-menu:active {
        background-color: rgba(0, 122, 255, 0.1) !important;
        transform: scale(0.98) !important;
    }
}

/* Final Footer Customization Touches */

/* Enhanced Footer Typography */
.store-footer {
    font-family: var(--footer-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
    line-height: 1.6;
    letter-spacing: 0.01em;
}

.store-footer h5 {
    font-size: var(--footer-heading-size, 1.1rem);
    font-weight: var(--footer-heading-weight, 600);
    letter-spacing: var(--footer-heading-spacing, 0.02em);
    margin-bottom: var(--footer-heading-margin, 1rem);
}

.store-footer p {
    font-size: var(--footer-text-size, 0.95rem);
    line-height: var(--footer-text-line-height, 1.6);
    margin-bottom: var(--footer-text-margin, 0.5rem);
}

/* Footer Spacing System */
.store-footer .container {
    padding: var(--footer-padding-y, 2rem) var(--footer-padding-x, 0);
}

.store-footer .row > div {
    padding: var(--footer-column-padding, 0 1rem);
    margin-bottom: var(--footer-column-margin, 1rem);
}

/* Footer Border and Shadow Refinements */
.store-footer {
    border: var(--footer-border-width, 0) solid var(--footer-border-color, transparent);
    border-radius: var(--footer-border-radius, 10px);
    box-shadow: var(--footer-box-shadow, 0 -2px 4px rgba(0, 0, 0, 0.1));
}

/* Footer Color Variables */
.store-footer {
    --footer-bg-color: var(--footer-bg-color, rgba(245, 245, 247, 0.9));
    --footer-text-color: var(--footer-text-color, #1D1D1F);
    --footer-heading-color: var(--footer-heading-color, #1D1D1F);
    --footer-link-color: var(--footer-link-color, #1D1D1F);
    --footer-link-hover-color: var(--footer-link-hover-color, #007AFF);
    --footer-separator-color: var(--footer-separator-color, rgba(0, 0, 0, 0.1));
}

/* Footer Link Enhancements */
.store-footer a {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.store-footer a:hover {
    color: var(--footer-link-hover-color, #007AFF);
    transform: translateY(-1px);
}

.store-footer a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--footer-link-hover-color, #007AFF);
    transition: width 0.3s ease;
}

.store-footer a:hover::after {
    width: 100%;
}

/* Footer Social Links Refinements */
.store-footer .social-links a {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.store-footer .social-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.store-footer .social-links a:hover::before {
    left: 100%;
}

/* Footer Responsive Grid System */
.store-footer[data-columns="1"] .row {
    display: flex;
    flex-direction: column;
}

.store-footer[data-columns="2"] .row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.store-footer[data-columns="3"] .row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.store-footer[data-columns="4"] .row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.store-footer[data-columns="5"] .row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
}

.store-footer[data-columns="6"] .row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.5rem;
}

/* Footer Mobile Optimizations */
@media (max-width: 768px) {
    .store-footer .row {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    .store-footer .row > div {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
        padding: 0 0.5rem !important;
    }
    
    .store-footer .social-links {
        display: flex;
        justify-content: center;
        gap: 0.5rem;
        margin-top: 1rem;
    }
}

@media (max-width: 576px) {
    .store-footer {
        margin: 0.5rem 0.25rem 0 0.25rem !important;
        border-radius: 6px !important;
    }
    
    .store-footer .container {
        padding: 1rem 0.5rem !important;
    }
    
    .store-footer h5 {
        font-size: 1rem !important;
        text-align: center !important;
    }
    
    .store-footer .social-links a {
        width: 35px !important;
        height: 35px !important;
        line-height: 35px !important;
        font-size: 0.9rem !important;
    }
}

/* Footer Print Styles */
@media print {
    .store-footer {
        background: white !important;
        color: black !important;
        box-shadow: none !important;
        border: 1px solid #ccc !important;
    }
    
    .store-footer .social-links {
        display: none !important;
    }
}

/* Footer High Contrast Mode */
@media (prefers-contrast: high) {
    .store-footer {
        border: 2px solid currentColor !important;
        background: white !important;
        color: black !important;
    }
    
    .store-footer a {
        text-decoration: underline !important;
    }
}

/* Footer Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .store-footer,
    .store-footer * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

