/* Base Box Model */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Root Variables */
:root {
    --main-color: #ff6600;
    --accent-color: #e65100;
    --background-color: #f4f4f4;
    --text-color: #2c2c2c;
    --success-color: #28a745;
    --error-color: #dc3545;
    --font-weight-regular: 400;
    --font-weight-bold: 700;
    --font-weight-light: 300;
}

/* Font Imports */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700&family=Montserrat:wght@300;400;700&family=Merriweather:wght@400&display=swap');

/* Global Styles */
body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-color);
    background-color: var(--background-color);
    margin: 0;
    padding: 0;
    font-size: 16px;
    line-height: 1.6;
    box-sizing: border-box;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
    background-color: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

/* Header */
header {
    background: var(--main-color);
    color: #fff;
    padding: 3rem 0;
    text-align: center;
}

header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 5rem;
    margin: 0;
    letter-spacing: 2px;
}

header img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 1.5rem;
    filter: grayscale(100%);
    transition: transform 0.3s ease-in-out;
}

header img:hover {
    transform: scale(1.1);
}

.header-text h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.5rem;
    margin-top: 0.5rem;
    font-weight: var(--font-weight-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Section Headings */
h3 {
    font-family: 'Merriweather', serif;
    font-weight: var(--font-weight-bold);
    border-bottom: 3px solid #000;
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
}

/* Persian Poem Style */
.poem p {
    font-family: 'Montserrat', serif;
    font-size: 1.5rem;
    font-weight: var(--font-weight-regular);
    color: #333;
    margin: 3rem auto;
    padding: 2rem 4rem;
    background-color: #fafafa;
    border-left: 6px solid #FF0000;
    text-align: center;
    max-width: 818px;
    line-height: 1.8;
}

/* Section Blocks */
.section:nth-child(even) {
    background-color: #fdfdfd;
}

.section {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.section-content {
    margin-left: 20px;
}

.section h2,
.section p {
    margin: 0;
}

/* Welcome Text */
.welcome-paragraph {
    text-align: left;
    margin: 10px 4px;
    font-size: 18px;
    line-height: 1.6;
    color: #ffffff;
    padding: 30px;
}

/* Links and Buttons */
a:focus, button:focus {
    outline: 2px solid #0056b3;
    outline-offset: 4px;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

a {
    color: var(--main-color);
    text-decoration: none;
    font-weight: var(--font-weight-bold);
    transition: color 0.3s;
}

a:hover {
    text-decoration: underline;
    color: var(--error-color);
}

/* Contact Section */
#contact {
    display: flex;
    align-items: center;
}

.logo {
    margin-right: 20px;
}

.about-content {
    display: flex;
    flex-direction: column;
}

/* Forms */
form {
    display: flex;
    flex-direction: column;
}

form label {
    margin-bottom: 5px;
}

form input, form textarea {
    margin-bottom: 15px;
    padding: 8px;
    width: 100%;
    min-width: 200px;
}

form button {
    padding: 10px;
    background-color: #007BFF;
    color: white;
    border: none;
    cursor: pointer;
}

form button:hover {
    background-color: #0056b3;
}

form button:active {
    transform: scale(0.98);
}

#formFeedback {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    font-size: 1rem;
}

.success {
    color: var(--success-color);
}

.error {
    color: var(--error-color);
    font-weight: var(--font-weight-bold);
}

/* CTA Button */
.cta-button {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--main-color);
    color: #fff;
    font-size: 36px;
    font-weight: var(--font-weight-bold);
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.cta-button:hover {
    background-color: var(--accent-color);
}

/* ======================
   Footer
   ====================== */

footer {
  text-align: center;
  background: #111;
  padding: 20px;
  font-size: 1em;
  border-top: 3px solid #555;
  color: #888;                  /* muted default for plain text */
}

.social-media-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.social-media-links li:not(:first-child)::before {
  content: "|";
  margin: 0 0.3rem;
  color: #555;
}

.social-media-links a {
  color: var(--brand);          /* orange by default */
  text-decoration: none;
  font-weight: 700;
  transition: color 0.25s ease, text-decoration 0.2s ease;
}

.social-media-links a:hover {
  color: var(--brand-900);      /* red on hover */
  text-decoration: underline;
  text-underline-offset: 2px;
}

.social-media-links a:focus-visible {
  outline: 3px solid var(--brand-900);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Optional: dim separators slightly on hover */
.social-media-links li:hover ~ li::before,
.social-media-links li:not(:first-child):hover::before {
  color: #666;
}

/* Dark mode tweak: lighten pipes so they stay visible */
@media (prefers-color-scheme: dark) {
  .social-media-links li:not(:first-child)::before {
    color: #999;
  }
}


/* Force brand colour on footer social links */
footer .social-media-links a:link,
footer .social-media-links a:visited {
  color: var(--brand, #ff2800);   /* fallback if --brand is missing */
  text-decoration: none;
  font-weight: 700;
  transition: color 0.25s ease, text-decoration 0.2s ease;
}

footer .social-media-links a:hover,
footer .social-media-links a:focus {
  color: var(--brand-900, #d40000);  /* darker on hover/focus */
  text-decoration: underline;
  text-underline-offset: 2px;
}

footer .social-media-links a:focus-visible {
  outline: 3px solid var(--brand-900, #d40000);
  outline-offset: 3px;
  border-radius: 6px;
}



/* ========== Persian Typography Enhancements ========== */

html[lang="fa"] body {
    font-family: 'IRANSans', 'Tahoma', 'Vazir', sans-serif;
    font-size: 18px;
    line-height: 2.4;
    direction: rtl;
}

html[lang="fa"] h1 {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.4;
    letter-spacing: -0.5px;
    font-family: 'B Titr', 'IRANSans', 'Tahoma', sans-serif;
}

html[lang="fa"] h2,
html[lang="fa"] .section-title {
    font-size: 2.4rem;
    font-weight: bold;
    color: var(--accent-color);
    border-right: 5px solid var(--accent-color);
    padding-right: 0.7rem;
}

html[lang="fa"] p,
html[lang="fa"] li {
    font-size: 1.4rem;
    line-height: 2.4;
    text-align: justify;
    color: #2a2a2a;
}

html[lang="fa"] a {
    font-size: 1.3rem;
}

html[lang="fa"] footer {
    font-size: 1rem;
    text-align: center;
    color: #aaa;
    border-top: 2px solid #444;
    padding: 1.5rem;
}

html[lang="fa"] .cta-button {
    font-size: 30px;
    padding: 14px 30px;
}

html[lang="fa"] .section {
    flex-direction: row-reverse;
}
