/* =====================================================
   Abasco Prime Vision Nig. Ltd - Main Stylesheet
   Theme: Elegant Islamic (Navy, Gold, Cream)
   Mobile-First App-Like Design
   ===================================================== */

:root {
    --primary: #1a2744;       /* Deep navy */
    --primary-light: #2c3e61;
    --secondary: #d4af37;     /* Gold */
    --secondary-dark: #b8962e;
    --cream: #f9f7f2;
    --white: #ffffff;
    --text: #333333;
    --text-light: #666666;
    --border: #e5e1d8;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
    --shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    --radius: 8px;
    --transition: all 0.3s ease;
    --header-height: 70px;
    --bottom-nav-height: 70px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: var(--text);
    background-color: var(--cream);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    /* iOS momentum scrolling */
    -webkit-overflow-scrolling: touch;
    overflow-x: hidden;
}

main {
    flex: 1;
    padding-bottom: 0;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

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

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

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

.section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.section-title p {
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    min-height: 44px; /* iOS minimum tap target */
}

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

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

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

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

.btn-whatsapp {
    background-color: #25d366;
    color: var(--white);
}

.btn-whatsapp:hover {
    background-color: #1ebe57;
    color: var(--white);
}

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

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

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

.btn-danger:hover {
    background-color: #c82333;
    color: var(--white);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.875rem;
}

/* Header */
.site-header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    max-width: 70%;
}

.logo-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.logo-icon {
    color: var(--secondary);
}

.main-nav .nav-list {
    display: flex;
    list-style: none;
    gap: 30px;
}

.main-nav .nav-list a {
    color: var(--text);
    font-weight: 500;
    padding: 8px 0;
    position: relative;
}

.main-nav .nav-list a:hover,
.main-nav .nav-list a.active {
    color: var(--secondary-dark);
}

.main-nav .nav-list a.active::after,
.main-nav .nav-list a:hover::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--secondary);
}

.has-dropdown {
    position: relative;
}

.has-dropdown .fa-chevron-down {
    font-size: 0.75rem;
}

.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--white);
    min-width: 200px;
    box-shadow: var(--shadow);
    border-radius: var(--radius);
    padding: 10px 0;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
}

.has-dropdown:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown a {
    display: block;
    padding: 10px 20px;
}

.dropdown a:hover {
    background-color: var(--cream);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary);
    cursor: pointer;
    min-width: 44px;
    min-height: 44px;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero .btn {
    margin: 0 10px 10px;
}

/* Features Bar */
.features-bar {
    background-color: var(--white);
    padding: 30px 0;
    border-bottom: 1px solid var(--border);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature-item i {
    font-size: 1.75rem;
    color: var(--secondary);
}

.feature-item h4 {
    font-size: 1rem;
    color: var(--primary);
}

.feature-item p {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 25px;
}

.product-card {
    background-color: var(--white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.product-image {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
    background-color: var(--cream);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: var(--secondary);
    color: var(--primary);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.product-info {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    font-size: 0.8rem;
    color: var(--secondary-dark);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.product-title {
    font-size: 1.1rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.product-price {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
}

.product-actions {
    margin-top: auto;
    display: flex;
    gap: 10px;
}

.product-actions .btn {
    flex: 1;
    padding: 10px;
    font-size: 0.875rem;
}

/* Categories */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.category-card {
    background-color: var(--white);
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-card i {
    font-size: 2.5rem;
    color: var(--secondary);
    margin-bottom: 15px;
}

.category-card h3 {
    color: var(--primary);
    margin-bottom: 5px;
}

/* About Section */
.about-section {
    background-color: var(--white);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-image {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.about-content h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.about-content p {
    margin-bottom: 15px;
    color: var(--text-light);
}

/* Filters */
.filters {
    background-color: var(--white);
    padding: 20px;
    border-radius: var(--radius);
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.filter-form {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: end;
}

.filter-form .form-group {
    flex: 1;
    min-width: 200px;
}

.filter-form label,
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--primary);
}

.filter-form input,
.filter-form select,
.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--secondary);
}

/* Product Detail */
.product-detail {
    background-color: var(--white);
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.product-detail-image {
    border-radius: var(--radius);
    overflow: hidden;
    background-color: var(--cream);
}

.product-detail-image img {
    width: 100%;
    height: auto;
}

.product-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.product-thumbnails .thumb {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: var(--radius);
    border: 2px solid transparent;
    cursor: pointer;
    flex-shrink: 0;
}

.product-thumbnails .thumb.active,
.product-thumbnails .thumb:hover {
    border-color: var(--secondary);
}

.product-detail-info h1 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.product-detail-price {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--secondary-dark);
    margin-bottom: 20px;
}

.product-detail-meta {
    margin-bottom: 25px;
}

.product-detail-meta p {
    margin-bottom: 8px;
}

.product-detail-description {
    color: var(--text-light);
    margin-bottom: 25px;
}

.size-options {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.size-options label {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
}

.size-options input[type="radio"] {
    margin: 0;
}

.order-form .form-group {
    margin-bottom: 15px;
}

.order-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.order-form input,
.order-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info-card {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.contact-info-card h3 {
    color: var(--primary);
    margin-bottom: 15px;
}

.contact-list {
    list-style: none;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    color: var(--text-light);
}

.contact-list i {
    color: var(--secondary);
    width: 20px;
}

.contact-form {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 20px;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: var(--radius);
    margin-bottom: 20px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state i {
    font-size: 3rem;
    color: var(--secondary);
    margin-bottom: 15px;
}

.empty-state h3 {
    color: var(--primary);
    margin-bottom: 10px;
}

/* Footer */
.site-footer {
    background-color: var(--primary);
    color: var(--white);
    padding-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    padding-bottom: 40px;
}

.footer-col h4 {
    color: var(--secondary);
    margin-bottom: 20px;
    font-size: 1.1rem;
}

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

.footer-col ul li {
    margin-bottom: 10px;
}

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

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

.footer-logo {
    color: var(--white);
    margin-bottom: 15px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    min-width: 44px;
    min-height: 44px;
}

.social-links a:hover {
    background-color: var(--secondary);
    color: var(--primary);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 0;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.footer-bottom .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.admin-access-link {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    padding: 10px;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.admin-access-link:hover {
    background-color: var(--secondary);
    color: var(--primary);
}

/* =====================================================
   MOBILE APP-LIKE STYLES
   ===================================================== */

/* Mobile bottom navigation - hidden by default on desktop */
.mobile-bottom-nav {
    display: none;
}

/* Responsive */
@media (max-width: 992px) {
    .about-grid,
    .contact-grid,
    .product-detail-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 60px;
    }

    body {
        padding-bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
    }

    main {
        padding-bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
    }

    .site-header {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        padding-top: env(safe-area-inset-top, 0px);
    }

    .header-inner {
        height: var(--header-height);
    }

    .logo {
        font-size: 1.1rem;
    }

    .main-nav {
        display: none; /* Hide desktop nav on mobile - use bottom nav */
    }

    .header-actions .btn-whatsapp {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    /* Push content below fixed header */
    .hero {
        padding-top: calc(var(--header-height) + 40px + env(safe-area-inset-top, 0px));
        padding-bottom: 50px;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .section {
        padding: 30px 0;
    }

    .section-title h2 {
        font-size: 1.5rem;
    }

    .container {
        padding: 0 15px;
    }

    /* Full-width product cards on mobile */
    .product-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-card {
        border-radius: 20px;
        flex-direction: row;
        align-items: stretch;
        min-height: 140px;
    }

    .product-image {
        width: 140px;
        min-width: 140px;
        aspect-ratio: auto;
        height: auto;
        border-radius: 20px 0 0 20px;
    }

    .product-image img {
        border-radius: 20px 0 0 20px;
    }

    .product-info {
        padding: 15px;
        justify-content: center;
    }

    .product-title {
        font-size: 1rem;
    }

    .product-price {
        font-size: 1.1rem;
    }

    .product-actions .btn {
        padding: 8px 12px;
    }

    /* Category cards full width */
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .category-card {
        padding: 20px 10px;
        border-radius: 20px;
    }

    .category-card i {
        font-size: 2rem;
    }

    .category-card h3 {
        font-size: 0.95rem;
    }

    /* Filters stacked */
    .filter-form {
        flex-direction: column;
    }

    .filter-form .form-group {
        min-width: 100%;
    }

    /* Product detail mobile */
    .product-detail {
        padding: 20px;
        border-radius: 24px;
        margin: 0 -15px;
    }

    .product-detail-info h1 {
        font-size: 1.5rem;
    }

    .product-detail-price {
        font-size: 1.4rem;
    }

    /* Contact form full width */
    .contact-info-card,
    .contact-form {
        padding: 20px;
        border-radius: 20px;
    }

    /* Larger form inputs */
    input,
    textarea,
    select,
    .btn {
        font-size: 16px; /* Prevents iOS zoom on focus */
    }

    /* Mobile bottom navigation bar */
    .mobile-bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
        padding-bottom: env(safe-area-inset-bottom, 0px);
        background-color: var(--white);
        box-shadow: 0 -2px 20px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        justify-content: space-around;
        align-items: center;
    }

    .mobile-nav-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 8px 4px;
        color: var(--text-light);
        font-size: 0.7rem;
        min-height: 44px;
    }

    .mobile-nav-item i {
        font-size: 1.25rem;
    }

    .mobile-nav-item.active {
        color: var(--primary);
    }

    .mobile-nav-item.active i {
        color: var(--secondary-dark);
    }

    .mobile-nav-cta {
        color: #25d366;
        font-weight: 600;
    }

    /* Footer padding for bottom nav */
    .site-footer {
        padding-bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 25px;
    }

    .footer-bottom {
        padding-bottom: calc(20px + var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
    }

    .footer-bottom .container {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .admin-access-link {
        width: 44px;
        height: 44px;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.5rem;
    }

    .product-card {
        min-height: 120px;
    }

    .product-image {
        width: 120px;
        min-width: 120px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* Smooth page transitions */
main {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
