/* =========================================
   Professional Design Overhaul
   ========================================= */

:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --text-color: #333;
    --border-radius: 4px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    color: var(--text-color);
    line-height: 1.6;
}

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

a:hover {
    color: var(--accent-color);
}

/* =========================================
   Header - Professional Redesign
   ========================================= */
.header {
    background-color: var(--primary-color);
    color: white;
    padding: 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.header-container {
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo a img {
    max-width: 150px;
    height: auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
    letter-spacing: 1px;
}

.nav-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 20px;
}

.nav-menu ul li a {
    color: white;
    padding: 15px 0;
    font-weight: 500;
    position: relative;
}

.nav-menu ul li a:hover {
    color: var(--light-color);
}

.nav-menu ul li a::after {
    content: '';
    position: absolute;
    bottom: 10px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--secondary-color);
    transition: var(--transition);
}

.nav-menu ul li a:hover::after {
    width: 100%;
}

/* =========================================
   Hero Section - Professional
   ========================================= */
.titleman {
    height: 400px;
    background: linear-gradient(rgba(44, 62, 80, 0.8), rgba(44, 62, 80, 0.9)), url('/static/bahai-haifa.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.titleman h1 {
    font-size: 2.8rem;
    margin-bottom: 20px;
    font-weight: 300;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.titleman .title {
    max-width: 800px;
    padding: 0 20px;
}

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

.cta-button {
    display: inline-block;
    background: var(--secondary-color);
    color: white;
    padding: 15px 30px;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 1.1rem;
    margin-top: 20px;
    transition: var(--transition);
    border: 2px solid var(--secondary-color);
    text-decoration: none;
}

.cta-button:hover {
    background: transparent;
    color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

/* Remove Lottie animation */
.dotlottie, .dotlottiearrow {
    display: none;
}

/* =========================================
   Section Headers
   ========================================= */
.latestads .container h2,
.featuredads .container h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 30px;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 10px;
}

.latestads .container h2::after,
.featuredads .container h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background-color: var(--secondary-color);
}

/* =========================================
   Cards - Professional Design
   ========================================= */
.ads, .featured-ads {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    padding: 20px 0;
}

.ad, .featured-ad {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid #eee;
}

.ad:hover, .featured-ad:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.ad img, .featured-ad img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.repairmantitle {
    background: var(--primary-color);
    color: white;
    padding: 15px;
    margin: 0;
}

.repairmantitle h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 500;
}

.description-wrapper {
    padding: 20px;
}

.description-wrapper p {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.6;
}

.ad p, .featured-ad p {
    padding: 0 20px;
    margin: 10px 0;
    color: #555;
}

.repairmanview {
    padding: 15px 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.repairmanview a {
    display: inline-block;
    background: var(--secondary-color);
    color: white;
    padding: 10px 25px;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
}

.repairmanview a:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* =========================================
   Categories - Professional
   ========================================= */
.display_categories {
    background: #f8f9fa;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}

.category-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    max-width: 1200px;
    margin: 0 auto;
}

.category-button {
    background: white;
    color: var(--primary-color);
    padding: 10px 20px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
}

.category-button:hover {
    background: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* =========================================
   News Widget - Professional
   ========================================= */
.latest-news-widget {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    margin: 20px 0;
}

.latest-news-widget-title {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.latest-news-widget-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.latest-news-widget-item {
    border: 1px solid #eee;
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: var(--transition);
}

.latest-news-widget-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.latest-news-widget-image {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.latest-news-widget-link {
    display: block;
    padding: 10px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
}

.latest-news-widget-date {
    padding: 0 10px;
    font-size: 0.85rem;
    color: #888;
}

.latest-news-widget-description {
    display: block;
    padding: 10px;
    color: #666;
    font-size: 0.9rem;
    text-decoration: none;
}

.latest-news-widget-description:hover {
    color: var(--secondary-color);
}

/* =========================================
   Footer - Professional
   ========================================= */
.footer {
    background-color: var(--primary-color);
    color: white;
    padding: 40px 0 20px;
    margin-top: auto;
}

.footer p {
    margin: 0;
    text-align: center;
    opacity: 0.9;
}

.footer a {
    color: white;
    opacity: 0.9;
    text-decoration: none;
}

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

/* =========================================
   Sections Backgrounds
   ========================================= */
.newadssec {
    padding: 60px 0;
    background: #f8f9fa;
}

.featuredadssec {
    padding: 60px 0;
    background: white;
}

/* =========================================
   Container Width
   ========================================= */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =========================================
   Hamburger Menu
   ========================================= */
.hamburger {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    color: white;
}

/* =========================================
   Trusted Repairmen - Professional
   ========================================= */
.trusted-repairmen {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    padding: 20px 0;
}

.repairman {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    text-align: center;
    transition: var(--transition);
}

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

.repairman img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid var(--secondary-color);
}

.repairman h3 {
    margin: 10px 0 5px;
    color: var(--primary-color);
}

.repairman p {
    color: #666;
    margin-bottom: 15px;
}

/* =========================================
   Login Page Styles
   ========================================= */
.Loginpage {
    padding: 10px;
    border: 1px solid #ccc;
    margin: 0;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #f0f0f0;
    color: #333;
}

/* =========================================
   Phone Number Styles
   ========================================= */
#phoneNumber {
    display: inline;
    margin-left: 5px;
    font-weight: bold;
}

#showPhoneNumber {
    cursor: pointer;
    text-decoration: underline;
    color: blue;
}

.adsbutton {
    border-radius: 5px;
    padding: 5px;
    background: #fff;
    margin: 5px 0px;
    width: 50%;
    text-align: center;
}

/* =========================================
   My Ads Section
   ========================================= */
section.myads {
    background: #474c54;
    margin: 5px 0px;
}

/* =========================================
   Latest News Title
   ========================================= */
section.titlelatestnews {
    border-radius: var(--border-radius);
    background: #f5e8ce;
    margin: 20px auto;
    max-width: 1200px;
    padding: 20px;
}

.titlelatestnews {
    padding: 4px 9px;
    margin: 5px;
}

/* =========================================
   Responsive Design
   ========================================= */
@media (max-width: 767px) {
    .header-container {
        flex-direction: column;
        padding: 15px;
        position: relative;
    }
    
    .nav-menu {
        width: 100%;
        display: none;
        background-color: var(--primary-color);
        text-align: center;
    }
    
    .nav-menu.active {
        display: block;
    }
    
    .nav-menu ul {
        flex-direction: column;
        gap: 0;
    }
    
    .nav-menu ul li {
        text-align: center;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-menu ul li a {
        display: block;
        padding: 12px;
    }
    
    .hamburger {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
        background: transparent;
        border: none;
        color: white;
        font-size: 1.5rem;
        cursor: pointer;
    }
    
    .titleman {
        height: 300px;
        padding: 20px 0;
    }
    
    .titleman h1 {
        font-size: 2rem;
    }
    
    .ads, .featured-ads {
        grid-template-columns: 1fr;
    }
    
    .latest-news-widget-row {
        grid-template-columns: 1fr;
    }
    
    .category-buttons {
        justify-content: center;
    }
    
    .ad, .featured-ad {
        width: 100%;
    }
    
    .trusted-repairmen {
        flex-direction: column;
        align-items: center;
    }
    
    .repairman {
        width: 100%;
    }
    
    .featured-ad {
        width: 100% !important;
    }
    
    .adsbutton {
        width: 100%;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .container {
        width: 95%;
        padding: 15px;
    }
    
    .ads, .featured-ads {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .trusted-repairmen {
        flex-direction: row;
        justify-content: space-around;
    }
    
    .repairman {
        width: calc(45% - 10px);
    }
    
    .featured-ad {
        width: calc(45% - 10px) !important;
    }
    
    .titleman h1 {
        font-size: 2em;
    }
}

/* =========================================
   Ad Info Page Styles
   ========================================= */
.adinfo {
    width: 80%;
    margin: 20px auto;
    background-color: white;
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    color: var(--text-color);
}

.adinfo h1 {
    color: var(--primary-color);
    margin-bottom: 15px;
    text-align: center;
}

.adinfo p {
    margin-bottom: 10px;
    line-height: 1.6;
}

.adinfo .adimage, .adinfo .adimages {
    margin-top: 20px;
    text-align: center;
}

.adinfo .adimage img, .adinfo .adimages img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    margin: 5px;
}

.adinfo .adinfocontact {
    margin-top: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.05);
}

.adinfo .adinfocontact h2 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.adinfo .adinfocontact p {
    margin-bottom: 8px;
}

.adinfobacktolistings {
    font-weight: bold;
    margin: 5px;
    background: var(--secondary-color);
    color: white;
    padding: 10px 20px;
    border-radius: var(--border-radius);
    text-decoration: none;
    display: inline-block;
}

.adinfobacktolistings:hover {
    background: #2980b9;
}

/* =========================================
   Additional Professional Elements
   ========================================= */
.section-title {
    text-align: center;
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 40px;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--secondary-color);
}

.container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.text-center {
    text-align: center;
}

.mt-40 { margin-top: 40px; }
.mb-40 { margin-bottom: 40px; }
.py-60 { padding: 60px 0; }

/* Add these styles to your existing style.css */

/* Animation for notifications */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

/* Ensure accessibility widget stays on top */
#accessibility-icon-container {
  position: fixed !important;
  z-index: 10000 !important;
}

/* Make sure no other elements cover the accessibility widget */
.header, .footer, .container, .ad-view-container {
  z-index: auto !important;
  position: relative !important;
}
