/* ========================================
   LOMISO - Institutional Knowledge Portal
   CSS Main Stylesheet
   ======================================== */

:root {
  --primary: #2C3E50;
  --secondary: #ECF0F1;
  --neutral: #BDC3C7;
  --accent-orange: #E67E22;
  --accent-green: #27AE60;
  --accent-yellow: #F1C40F;
  --text-dark: #2C3E50;
  --text-light: #7F8C8D;
  --border-light: #BDC3C7;
  --bg-light: #F8F9FA;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --spacing-base: 8px;
}

/* ========================================
   RESET & BASE STYLES
   ======================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Merriweather', 'Lora', serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--secondary);
  letter-spacing: 0.5px;
}

/* ========================================
   TYPOGRAPHY
   ======================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
  line-height: 1.2;
}

h1 {
  font-size: 3.5rem;
  font-weight: 700;
  letter-spacing: -1px;
  margin-bottom: 1.5rem;
  color: var(--primary);
}

h2 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.75rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 1rem;
}

h4 {
  font-size: 1.375rem;
  font-weight: 600;
}

h5 {
  font-size: 1.125rem;
  font-weight: 600;
}

h6 {
  font-size: 1rem;
  font-weight: 600;
}

p {
  margin-bottom: 1.25rem;
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-dark);
}

a {
  color: var(--accent-orange);
  text-decoration: none;
  transition: color 0.3s ease, text-decoration 0.3s ease;
}

a:hover {
  color: var(--primary);
  text-decoration: underline;
}

strong {
  font-weight: 600;
  color: var(--primary);
}

em {
  font-style: italic;
  color: var(--text-dark);
}

ul, ol {
  margin-left: 2rem;
  margin-bottom: 1.5rem;
}

li {
  margin-bottom: 0.75rem;
  line-height: 1.8;
}

blockquote {
  border-left: 4px solid var(--accent-orange);
  padding: 1.5rem 2rem;
  margin: 2rem 0;
  background-color: rgba(230, 126, 34, 0.05);
  font-style: italic;
  color: var(--text-dark);
}

/* ========================================
   CONTAINER & LAYOUT
   ======================================== */

.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 2rem;
}

.container-full {
  width: 100%;
  margin: 0 auto;
}

.content-wrapper {
  max-width: 1280px;
  margin: 0 auto;
}

/* ========================================
   HEADER & NAVIGATION
   ======================================== */

header {
  background-color: #fff;
  border-bottom: 1px solid var(--neutral);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 0;
  max-width: 1140px;
  margin: 0 auto;
  padding-left: 2rem;
  padding-right: 2rem;
}

.logo {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary);
  font-family: 'IBM Plex Sans', sans-serif;
  letter-spacing: -1px;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2.5rem;
  margin: 0;
}

nav a {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--text-dark);
  text-decoration: none;
  transition: color 0.3s ease, border-bottom 0.3s ease;
  padding-bottom: 0.25rem;
  border-bottom: 2px solid transparent;
}

nav a:hover,
nav a.active {
  color: var(--accent-orange);
  border-bottom-color: var(--accent-orange);
}

/* ========================================
   FOOTER
   ======================================== */

footer {
  background-color: var(--primary);
  color: #fff;
  padding: 4rem 2rem 2rem;
  margin-top: 6rem;
}

.footer-inner {
  max-width: 1140px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: #fff;
  margin-bottom: 1rem;
  font-size: 1rem;
}

.footer-section ul {
  list-style: none;
  margin: 0;
}

.footer-section li {
  margin-bottom: 0.75rem;
}

.footer-section a {
  color: var(--secondary);
  transition: color 0.3s ease;
}

.footer-section a:hover {
  color: var(--accent-orange);
  text-decoration: none;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero {
  background: linear-gradient(rgba(44, 62, 80, 0.7), rgba(44, 62, 80, 0.7)),
              url('/images/hero-nutrition.jpg') center/cover no-repeat;
  color: #fff;
  padding: 8rem 2rem;
  text-align: center;
  margin-bottom: 3rem;
}

.hero h1 {
  color: #fff;
  font-size: 4rem;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.95);
  max-width: 800px;
  margin: 0 auto 2rem;
}

/* ========================================
   BUTTON STYLES
   ======================================== */

.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  border-radius: 4px;
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.btn-primary:hover {
  background-color: var(--accent-orange);
  border-color: var(--accent-orange);
}

.btn-secondary {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-secondary:hover {
  background-color: var(--primary);
  color: #fff;
}

.btn-outline {
  background-color: transparent;
  color: var(--text-dark);
  border-color: var(--text-dark);
}

.btn-outline:hover {
  background-color: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.btn-accent {
  background-color: var(--accent-orange);
  color: #fff;
  border-color: var(--accent-orange);
}

.btn-accent:hover {
  background-color: var(--primary);
  border-color: var(--primary);
}

/* ========================================
   SECTION STYLES
   ======================================== */

section {
  padding: 6rem 2rem;
}

section.alt {
  background-color: var(--bg-light);
}

section.highlight {
  background-color: var(--primary);
  color: #fff;
}

section.highlight h2,
section.highlight h3 {
  color: #fff;
}

section.highlight p {
  color: rgba(255, 255, 255, 0.95);
}

/* ========================================
   TWO-COLUMN LAYOUT
   ======================================== */

.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.two-column.reverse {
  direction: rtl;
}

.two-column.reverse > * {
  direction: ltr;
}

.two-column-content {
  flex: 1;
}

.two-column-image {
  flex: 1;
}

.two-column-image img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: var(--shadow-md);
}

/* ========================================
   GRID & CARD LAYOUTS
   ======================================== */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  margin-bottom: 2rem;
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  background: #fff;
  border: 1px solid var(--neutral);
  border-radius: 4px;
  padding: 2rem;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--accent-orange);
}

.card h3 {
  margin-top: 0;
}

.card-icon {
  width: 48px;
  height: 48px;
  background-color: var(--accent-orange);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.card-meta {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.875rem;
  color: var(--text-light);
  margin-bottom: 1rem;
}

/* ========================================
   BLOG & ARTICLE STYLES
   ======================================== */

.blog-card {
  background: #fff;
  border: 1px solid var(--neutral);
  border-radius: 4px;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.blog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.blog-card-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.blog-card-content {
  padding: 2rem;
}

.blog-card-date {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.875rem;
  color: var(--text-light);
  margin-bottom: 0.75rem;
}

.blog-card h3 {
  margin-top: 0;
  margin-bottom: 1rem;
}

.blog-card p {
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.article-hero {
  background: linear-gradient(rgba(44, 62, 80, 0.8), rgba(44, 62, 80, 0.8)),
              url('/images/hero-nutrition.jpg') center/cover no-repeat;
  color: #fff;
  padding: 4rem 2rem;
  text-align: center;
  margin-bottom: 3rem;
  border-radius: 4px;
}

.article-hero h1 {
  color: #fff;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.article-meta {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.9);
}

.article-content {
  max-width: 900px;
  margin: 0 auto 3rem;
}

.article-content img {
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: var(--shadow-md);
  margin: 2rem 0;
}

/* ========================================
   FORM STYLES
   ======================================== */

.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  font-family: 'IBM Plex Sans', sans-serif;
  color: var(--primary);
}

input[type="text"],
input[type="email"],
input[type="phone"],
input[type="url"],
textarea,
select {
  width: 100%;
  padding: 0.875rem;
  border: 1px solid var(--neutral);
  border-radius: 4px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-dark);
  transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="phone"]:focus,
input[type="url"]:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.1);
}

textarea {
  resize: vertical;
  min-height: 120px;
}

.form-message {
  padding: 1rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.95rem;
}

.form-message.success {
  background-color: rgba(39, 174, 96, 0.1);
  color: var(--accent-green);
  border-left: 4px solid var(--accent-green);
}

.form-message.error {
  background-color: rgba(230, 126, 34, 0.1);
  color: var(--accent-orange);
  border-left: 4px solid var(--accent-orange);
}

/* ========================================
   TABLE STYLES
   ======================================== */

table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 2rem;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

thead {
  background-color: var(--primary);
  color: #fff;
}

th {
  padding: 1rem;
  text-align: left;
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 600;
}

td {
  padding: 1rem;
  border-bottom: 1px solid var(--neutral);
}

tbody tr:hover {
  background-color: var(--bg-light);
}

/* ========================================
   SPACING UTILITIES
   ======================================== */

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 3rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 3rem; }

.pt-0 { padding-top: 0; }
.pt-1 { padding-top: 0.5rem; }
.pt-2 { padding-top: 1rem; }
.pt-3 { padding-top: 1.5rem; }
.pt-4 { padding-top: 2rem; }
.pt-5 { padding-top: 3rem; }

.pb-0 { padding-bottom: 0; }
.pb-1 { padding-bottom: 0.5rem; }
.pb-2 { padding-bottom: 1rem; }
.pb-3 { padding-bottom: 1.5rem; }
.pb-4 { padding-bottom: 2rem; }
.pb-5 { padding-bottom: 3rem; }

/* ========================================
   UTILITY CLASSES
   ======================================== */

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

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

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

.text-muted {
  color: var(--text-light);
}

.text-accent {
  color: var(--accent-orange);
}

.text-success {
  color: var(--accent-green);
}

.text-warning {
  color: var(--accent-yellow);
}

.bg-primary {
  background-color: var(--primary);
  color: #fff;
}

.bg-secondary {
  background-color: var(--secondary);
}

.bg-light {
  background-color: var(--bg-light);
}

.bg-accent {
  background-color: var(--accent-orange);
  color: #fff;
}

.border-top {
  border-top: 1px solid var(--neutral);
}

.border-bottom {
  border-bottom: 1px solid var(--neutral);
}

.rounded {
  border-radius: 4px;
}

.shadow {
  box-shadow: var(--shadow-sm);
}

.shadow-md {
  box-shadow: var(--shadow-md);
}

.hidden {
  display: none;
}

.visible {
  display: block;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
  h1 {
    font-size: 2.5rem;
  }

  h2 {
    font-size: 2rem;
  }

  h3 {
    font-size: 1.5rem;
  }

  .hero {
    padding: 4rem 1.5rem;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  section {
    padding: 4rem 1.5rem;
  }

  .header-inner {
    flex-direction: column;
    gap: 1rem;
  }

  nav ul {
    flex-direction: column;
    gap: 1rem;
  }

  .two-column {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .two-column.reverse {
    direction: ltr;
  }

  .grid,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .container {
    padding: 0 1.5rem;
  }

  .header-inner {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  h3 {
    font-size: 1.25rem;
  }

  body {
    font-size: 15px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  nav ul {
    gap: 0.75rem;
  }

  nav a {
    font-size: 0.9rem;
  }

  .container {
    padding: 0 1rem;
  }

  section {
    padding: 3rem 1rem;
  }
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
  header,
  footer,
  .no-print {
    display: none;
  }

  body {
    background: #fff;
  }

  a {
    text-decoration: underline;
  }
}
