/* --- Core Styling Variables --- */
:root {
    --sabbar-orange: #ff5a22;
    --sabbar-orange-hover: #e04814;
    --bg-gray: #fafafa;
    --border-input: #d1d5db;
    --text-dark: #1f2937;
    --text-muted: #6b7280;
    --card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.02), 0 8px 10px -6px rgba(0, 0, 0, 0.02);
}

/* --- Global Configurations --- */
body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Cairo', system-ui, sans-serif;
    background-color: var(--bg-gray);
    color: var(--text-dark);
}

/* --- Navigation Header (نفس تنسيق الهيدر المستخدم بالصفحة الرئيسية index.html/homepage.css حرفياً) --- */
.main-navbar {
    width: 100%;
    background-color: #ffffff;
    border-bottom: 1px solid #f3f4f6;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 8%;
    background-color: #ffffff;
}

.logo {
    font-size: 22px;
    display: flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    color: inherit;
}

.logo-circle {
    margin-top: 8px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.nav-links a {
    margin: 0 15px;
    text-decoration: none;
    color: #333333;
    font-weight: 500;
    font-size: 15px;
}

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

.lang-switch {
    text-decoration: none;
    color: #333333;
    font-weight: bold;
    margin-right: 10px;
}

.btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    transition: background 0.3s ease;
}

.btn-register {
    background-color: #030303;
    color: white;
    border: none;
}

.btn-login {
    background-color: white;
    color: #030303;
    border: 1px solid #030303;
}

/* تأثير التلاشي للترجمة الديناميكية عند تبديل اللغة (homepage.js) */
[data-i18n] {
    transition: opacity 0.25s ease-in-out;
    opacity: 1;
}
.fade-out {
    opacity: 0 !important;
}

/* --- Layout Structure & Floating Card Container --- */
.page-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 80px);
    padding: 40px 20px;
}
.contact-card {
    background-color: #ffffff;
    width: 100%;
    max-width: 540px;
    padding: 40px;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    border: 1px solid #f3f4f6;
    box-sizing: border-box;
}
.form-title {
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    margin: 0 0 8px 0;
    color: var(--text-dark);
}
.form-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
    margin: 0 0 32px 0;
}

/* --- Form Fields Component Styles --- */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
}
.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    color: var(--text-dark);
    background-color: #ffffff;
    border: 1px solid var(--border-input);
    border-radius: 8px;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--sabbar-orange);
    box-shadow: 0 0 0 3px rgba(255, 90, 34, 0.1);
}

/* Custom Select Treatment */
.select-wrapper {
    position: relative;
    width: 100%;
}
.select-wrapper::after {
    content: "▼";
    font-size: 10px;
    color: var(--text-muted);
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}
.select-wrapper select {
    appearance: none;
    -webkit-appearance: none;
    padding-left: 40px; /* Space for the arrow indicator */
}

/* Special Phone Country Code Entry Layout */
.phone-input-wrapper {
    display: flex;
    position: relative;
    align-items: center;
}
.phone-input-wrapper input {
    padding-left: 95px; /* Offset to make room for country badge */
}
.country-prefix {
    position: absolute;
    left: 1px;
    height: calc(100% - 2px);
    background-color: #f9fafb;
    border-right: 1px solid var(--border-input);
    border-radius: 8px 0 0 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 12px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    direction: ltr;
}

/* --- Submit Activation Button --- */
.submit-btn {
    width: 100%;
    background-color: var(--sabbar-orange);
    color: #ffffff;
    border: none;
    padding: 14px;
    font-size: 15px;
    font-weight: 700;
    border-radius: 24px;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 10px;
}
.submit-btn:hover {
    background-color: var(--sabbar-orange-hover);
}

/* --- Mobile Breakpoint Optimization Rules --- */
@media (max-width: 768px) {
    .contact-card {
        padding: 24px;
    }
}

@media (max-width: 600px) {
    .navbar {
        flex-direction: column;
        gap: 15px;
    }
}