/*
Theme Name: Anqara (Cons Theme)
Theme URI: https://anqara.com
Author: Anqara Team
Description: Custom WordPress theme for Anqara General Contracting. Built with Tailwind CSS.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: anqara
*/

/* Global Luxuries & Overrides */
body {
    background-color: #020A07;
    color: #F3F4F6;
    overflow-x: hidden;
}

/* The Cinema Grain Overlay */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Typography Selection */
::selection {
    background: #d4af37;
    color: #000;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #061C15;
}

::-webkit-scrollbar-thumb {
    background: #d4af37;
    border-radius: 4px;
}

/* Utility: Text Stroke */
.text-stroke {
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.1);
    color: transparent;
}

/* Smooth Image Hover Zoom */
.img-zoom-container {
    overflow: hidden;
}

.img-zoom-container img {
    transition: transform 1.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.img-zoom-container:hover img {
    transform: scale(1.05);
}

/* Global Animations (Migrated from templates) */
@keyframes pan {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.1);
    }
}

@keyframes fadeUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-slow-pan {
    animation: pan 30s linear infinite alternate;
}

.animate-fade-up {
    animation: fadeUp 1s ease-out forwards;
}

/* Animations using IntersectionObserver */
.reveal-text,
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.25, 1, 0.5, 1);
}

.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays if needed */
.delay-100 {
    transition-delay: 100ms;
}

.delay-200 {
    transition-delay: 200ms;
}

.delay-300 {
    transition-delay: 300ms;
}

/* --- New Sections Support --- */

/* Timeline (Methodology) */
.timeline-step {
    position: relative;
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.3s ease;
}

.timeline-step:hover {
    border-color: #d4af37;
    transform: translateY(-5px);
}

.timeline-step::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -1rem;
    /* Adjust for RTL */
    width: 2rem;
    height: 1px;
    background: #d4af37;
    opacity: 0;
    transition: opacity 0.3s;
}

.timeline-step:hover::after {
    opacity: 1;
}

.timeline-step:last-child::after {
    display: none;
}

/* FAQ Accordion */
.faq-details {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-top: none;
}

.faq-summary {
    list-style: none;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-summary::-webkit-details-marker {
    display: none;
}

.faq-summary:hover,
details[open] .faq-summary {
    background: rgba(197, 160, 89, 0.1);
    border-color: rgba(197, 160, 89, 0.3);
}

.faq-summary h4 {
    margin: 0;
    font-weight: 600;
}

.faq-icon {
    transition: transform 0.3s ease;
}

details[open] .faq-icon {
    transform: rotate(45deg);
    color: #d4af37;
}

/* Form Styles - Premium High Contrast */
.form-input {
    width: 100%;
    background: #000000 !important;
    border: 1.5px solid rgba(212, 175, 55, 0.5) !important;
    color: #ffffff !important;
    padding: 1.1rem 1.25rem;
    border-radius: 0.6rem;
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.05rem;
    forced-color-adjust: none;
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-input:hover {
    border-color: rgba(212, 175, 55, 0.8) !important;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.1);
}

.form-input:focus {
    border-color: #ffffff !important;
    background: #000000 !important;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
}

/* Specific styling for Select Dropdowns */
select.form-input {
    appearance: none;
    -webkit-appearance: none;
    background-color: #000000 !important;
    color-scheme: dark !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23d4af37' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 1.25rem center;
    background-size: 1.1em;
    padding-left: 3.5rem;
    cursor: pointer;
    font-weight: 600;
}

select.form-input option {
    background-color: #000000 !important;
    color: #ffffff !important;
    padding: 15px;
    font-size: 1.1rem;
}


.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: #F3F4F6;
    /* Brightened label for better contrast */
    font-size: 0.9rem;
    font-weight: 500;
}

/* ========================================
   ACCESSIBILITY: Focus States
   ======================================== */

/* Universal focus state for keyboard navigation */
:focus-visible {
    outline: 2px solid #d4af37;
    outline-offset: 2px;
}

/* Remove default focus outline when not using keyboard */
:focus:not(:focus-visible) {
    outline: none;
}

/* Enhanced focus for buttons */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #d4af37;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Skip to content link */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ========================================
   PLUGIN SUPPORT: Contact Form 7
   ======================================== */
.wpcf7-form p {
    margin-bottom: 1.5rem;
}

.wpcf7-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: #9CA3AF;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.wpcf7-form-control-wrap {
    display: block;
}

.wpcf7-text,
.wpcf7-textarea,
.wpcf7-select,
.wpcf7-number,
.wpcf7-date {
    width: 100%;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem;
    color: white;
    transition: all 0.3s ease;
    outline: none;
    border-radius: 0.125rem;
    /* rounded-sm */
    font-family: inherit;
}

.wpcf7-text:focus,
.wpcf7-textarea:focus,
.wpcf7-select:focus {
    border-color: #d4af37;
    background: rgba(197, 160, 89, 0.05);
}

.wpcf7-submit {
    width: 100%;
    background-color: #d4af37;
    color: #020A07;
    font-weight: 700;
    padding: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0.125rem;
}

.wpcf7-submit:hover {
    background-color: #ffffff;
    color: #000000;
}

.wpcf7-spinner {
    margin-top: 1rem;
}

.wpcf7-not-valid-tip {
    color: #f87171;
    /* red-400 */
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

.wpcf7-response-output {
    margin-top: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 1rem !important;
    border-radius: 4px;
    font-size: 0.9rem;
}

/* ========================================
   MOBILE MENU ANIMATIONS
   ======================================== */

/* Menu items visible by default (animation handled via JS if needed) */
.mobile-menu-item {
    opacity: 1;
    transform: translateX(0);
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Visible state - triggered by JavaScript */
.mobile-menu-item--visible {
    opacity: 1;
    transform: translateX(0);
}

/* CTA and social items have different initial transform */
.mobile-menu-item.translate-y-4 {
    transform: translateY(1rem);
}

.mobile-menu-item--visible.translate-y-4,
.mobile-menu-item--visible[class*="translate-y"] {
    transform: translateY(0);
}

/* ========================================
   HEADER SCROLL EFFECT
   ======================================== */

#site-header {
    transition: all 0.3s ease;
}

#site-header.header-scrolled {
    background: rgba(6, 28, 21, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom-color: rgba(212, 175, 55, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Reduce padding when scrolled for more compact header */
#site-header.header-scrolled>div {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* ========================================
   NAVIGATION MENU STYLES
   ======================================== */

/* Desktop Menu - Center-out Underline Animation */
.desktop-nav-menu {
    display: flex;
    align-items: center;
    gap: 4rem;
}

.desktop-nav-menu li {
    list-style: none;
}

.desktop-nav-menu a {
    position: relative;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
    text-decoration: none;
}

.desktop-nav-menu a:hover,
.desktop-nav-menu .current-menu-item a {
    color: #d4af37;
}

/* Center-out underline effect */
.desktop-nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    width: 0;
    height: 2px;
    background-color: #d4af37;
    transition: all 0.3s ease;
}

.desktop-nav-menu a:hover::after,
.desktop-nav-menu .current-menu-item a::after {
    width: 100%;
    right: 0;
}

/* ========================================
   SAFE AREA INSET (Notched Devices)
   ======================================== */

/* iOS Safari support for notched devices */
@supports (padding: max(0px)) {
    body {
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }

    #site-header {
        padding-left: max(1.5rem, env(safe-area-inset-left));
        padding-right: max(1.5rem, env(safe-area-inset-right));
    }

    #mobile-menu-overlay {
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
        padding-bottom: env(safe-area-inset-bottom);
    }
}