/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #000000; /* Black */
    --accent-color: #333333; /* Dark Gray */
    --bg-color: #ffffff; /* White */
    --text-color: #000000; /* Black */
    --text-light: #666666; /* Gray */
    --border-color: #000000; /* Black borders for high contrast/minimal look */
    --radius: 0px; /* Sharp corners for brutalist/minimal feel */
    --transition: all 0.2s ease;
}

body {
    font-family: 'Courier New', Courier, monospace; /* Monospace for raw/minimal feel, or stick to Cairo/sans-serif */
    /* Let's stick to a clean sans-serif but maybe simpler */
    font-family: 'Cairo', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative; /* Ensure absolute children are positioned relative to this */
}

/* Header */
.main-header {
    text-align: center;
    padding: 80px 0 40px;
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 15px;
}

.logo-icon {
    font-size: 2.5rem;
    filter: grayscale(100%);
}

.main-logo {
    height: 80px;
    width: auto;
}

.main-header h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tagline {
    font-size: 1.1rem;
    color: var(--text-light);
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Search Container */
.search-container {
    width: 100%;
    max-width: 800px;
    margin-bottom: 60px;
}

.url-form {
    width: 100%;
}

.input-group {
    display: flex;
    gap: 0; /* Connected inputs */
    position: relative;
    border: 2px solid var(--border-color);
}

.url-input {
    flex: 1;
    padding: 15px 20px;
    font-size: 1.1rem;
    border: none;
    border-radius: 0;
    background: #fff;
    color: var(--text-color);
    font-family: inherit;
    transition: var(--transition);
}

.url-input:focus {
    outline: none;
    background: #f5f5f5;
}

.browse-btn {
    padding: 0 30px;
    background-color: var(--primary-color);
    color: white;
    border: none; /* Border is handled by container */
    border-left: 2px solid var(--border-color); /* Separator */
    border-radius: 0;
    font-size: 1.1rem;
    font-family: inherit;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

[dir="rtl"] .browse-btn {
    border-left: none;
    border-right: 2px solid var(--border-color);
}

.browse-btn:hover {
    background-color: #333;
}

.browse-btn .icon {
    width: 20px;
    height: 20px;
}

/* Error Message */
.error-message {
    margin-top: 15px;
    padding: 12px;
    background-color: #fff;
    color: #000;
    border: 2px solid #000;
    display: flex;
    align-items: center;
    gap: 10px;
}

.error-message .icon {
    width: 20px;
    height: 20px;
}

/* Features Grid */
.features {
    width: 100%;
    margin-bottom: 60px;
}

.features h2, .how-it-works h2, .popular-sites h2 {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 40px;
    font-size: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-bottom: 2px solid #000;
    display: table;
    margin-left: auto;
    margin-right: auto;
    padding-bottom: 10px;
}

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

.feature-card {
    background: #fff;
    padding: 25px;
    border: 2px solid var(--border-color);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    background-color: #000;
    color: #fff;
}

.feature-card:hover p, .feature-card:hover h3 {
    color: #fff;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
    filter: grayscale(100%);
}

.feature-card h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

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

/* How It Works */
.how-it-works {
    width: 100%;
    margin-bottom: 60px;
    background-color: #fff;
    padding: 40px;
    border: 2px solid #000;
}

.steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
}

.step {
    text-align: center;
    flex: 1;
}

.step-number {
    width: 50px;
    height: 50px;
    background-color: #000;
    color: white;
    border-radius: 0; /* Square */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 15px;
}

.step p {
    font-weight: 600;
    color: var(--text-color);
}

.step-arrow {
    color: #000;
    font-size: 2rem;
    font-weight: 700;
}

/* Popular Sites */
.popular-sites {
    width: 100%;
    margin-bottom: 40px;
}

.sites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

.site-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    background-color: white;
    border: 2px solid var(--border-color);
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
    transition: var(--transition);
}

.site-btn:hover {
    background-color: #000;
    color: white;
}

/* Navbar Styles */
.navbar {
    background-color: #fff;
    border-bottom: 2px solid #000;
    padding: 15px 0;
    margin-bottom: 30px;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: #000;
}

.logo-img {
    height: 40px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 25px;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: #000;
    font-weight: 600;
    font-size: 1rem;
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #000;
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Language Dropdown */
.lang-dropdown {
    position: relative;
}

.lang-btn-toggle {
    background: none;
    border: 2px solid #000;
    padding: 8px 15px;
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.lang-btn-toggle:hover {
    background-color: #000;
    color: #fff;
}

.lang-menu {
    position: absolute;
    top: 100%;
    right: 0; /* Align right for LTR */
    background: #fff;
    border: 2px solid #000;
    min-width: 150px;
    display: none;
    flex-direction: column;
    z-index: 1000;
    margin-top: 5px;
}

[dir="rtl"] .lang-menu {
    left: 0;
    right: auto;
}

.lang-menu.show {
    display: flex;
}

.lang-menu a {
    padding: 10px 15px;
    text-decoration: none;
    color: #000;
    font-weight: 600;
    border-bottom: 1px solid #eee;
    transition: background 0.2s;
}

.lang-menu a:last-child {
    border-bottom: none;
}

.lang-menu a:hover, .lang-menu a.active {
    background-color: #f0f0f0;
}

/* Info Sections */
.info-section {
    width: 100%;
    margin-bottom: 60px;
    text-align: center;
}

.info-section h2 {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 40px;
    font-size: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-bottom: 2px solid #000;
    display: table;
    margin-left: auto;
    margin-right: auto;
    padding-bottom: 10px;
}

/* Info Grid (Why Use) */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.info-card {
    background: #fff;
    padding: 25px;
    border: 2px solid #000;
    transition: var(--transition);
    text-align: left;
}

[dir="rtl"] .info-card {
    text-align: right;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 5px 5px 0px #000;
}

.info-card h3 {
    margin-bottom: 15px;
    font-size: 1.3rem;
    font-weight: 700;
}

/* Text Content (How Proxy Works) */
.text-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: center;
}

/* Security Grid */
.security-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.security-card {
    background: #f9f9f9;
    padding: 30px;
    border: 2px solid #000;
    text-align: center;
}

.security-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.security-card h3 {
    margin-bottom: 15px;
    font-size: 1.3rem;
}

/* Use Cases */
.use-cases-list {
    list-style: none;
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
    border: 2px solid #000;
    padding: 30px;
    background: #fff;
}

[dir="rtl"] .use-cases-list {
    text-align: right;
}

.use-cases-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.use-cases-list li:last-child {
    margin-bottom: 0;
}

.check-icon {
    color: #000;
    font-weight: bold;
    font-size: 1.2rem;
}

/* FAQ */
.faq-grid {
    display: grid;
    gap: 20px;
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: #fff;
    border: 2px solid #000;
    padding: 20px;
    text-align: left;
}

[dir="rtl"] .faq-item {
    text-align: right;
}

.faq-question {
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.faq-answer {
    color: #444;
    line-height: 1.6;
}

/* Blog Styles */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.blog-card {
    background: #fff;
    border: 2px solid #000;
    transition: var(--transition);
    overflow: hidden;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 5px 5px 0px #000;
}

.blog-card-content {
    padding: 25px;
}

.blog-date {
    font-size: 0.9rem;
    color: #666;
    display: block;
    margin-bottom: 10px;
}

.blog-card h2 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    line-height: 1.3;
}

.blog-card h2 a {
    color: #000;
    text-decoration: none;
}

.blog-card p {
    color: #444;
    margin-bottom: 20px;
    line-height: 1.6;
}

.read-more {
    color: var(--primary-color);
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
}

/* Single Article Styles */
.single-article {
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    padding: 40px;
    border: 2px solid #000;
}

.article-header {
    margin-bottom: 40px;
    text-align: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 30px;
}

.back-link {
    display: inline-block;
    margin-bottom: 20px;
    color: #666;
    text-decoration: none;
}

.article-title {
    font-size: 2.5rem;
    margin-bottom: 15px;
    line-height: 1.2;
}

.article-meta {
    color: #666;
}

.article-body {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

.article-body h2 {
    font-size: 1.8rem;
    margin-top: 40px;
    margin-bottom: 20px;
    border-bottom: 2px solid #000;
    padding-bottom: 10px;
    display: inline-block;
}

.article-body h3 {
    font-size: 1.4rem;
    margin-top: 30px;
    margin-bottom: 15px;
    font-weight: 700;
}

.article-body p {
    margin-bottom: 20px;
}

.article-body ul, .article-body ol {
    margin-bottom: 20px;
    padding-left: 20px;
    padding-right: 20px;
}

.article-body li {
    margin-bottom: 10px;
}

.article-footer {
    margin-top: 60px;
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.cta-button {
    display: inline-block;
    background: #000;
    color: #fff;
    padding: 15px 40px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.2rem;
    transition: var(--transition);
}

.cta-button:hover {
    background: var(--primary-color);
    transform: scale(1.05);
}

[dir="rtl"] .back-link {
    transform: scaleX(-1);
}

/* Footer Updates */
.main-footer {
    margin-top: auto;
    padding: 30px 0;
    border-top: 2px solid var(--border-color);
    text-align: center;
}

.footer-description {
    max-width: 600px;
    margin: 0 auto 20px;
    color: #444;
    font-size: 1.1rem;
    line-height: 1.6;
}

.footer-nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 15px;
}

.footer-nav a {
    color: #000;
    text-decoration: none;
    font-weight: 600;
}

.footer-nav a:hover {
    text-decoration: underline;
}

.copyright {
    color: #666;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    .nav-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-links {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .logo-text {
        display: none; /* Save space on mobile */
    }

    .main-header {
        padding: 40px 0 30px;
    }

    .main-header h1 {
        font-size: 1.8rem;
    }

    .input-group {
        flex-direction: column;
        border: none;
        gap: 10px;
    }

    .url-input {
        border: 2px solid #000;
    }

    .browse-btn {
        width: 100%;
        padding: 15px;
        justify-content: center;
        border: 2px solid #000;
    }

    .steps {
        flex-direction: column;
        gap: 20px;
    }

    .step-arrow {
        transform: rotate(90deg);
        margin: 10px 0;
    }
}
