/* ============================================
   Consultancy Grid — Modern 2026 Redesign
   ============================================ */

:root {
  --color-primary: #1a73e8;
  --color-primary-dark: #1557b0;
  --color-accent: #34a853;
  --color-accent-hover: #2d9249;
  --color-text: #1f2937;
  --color-text-light: #6b7280;
  --color-bg: #f3f4f6;
  --color-surface: #ffffff;
  --color-border: #e5e7eb;
  --color-header-from: #0f172a;
  --color-header-to: #1e3a5f;
  --color-footer-bg: #0f172a;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -1px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.03);
  --radius: 8px;
  --radius-lg: 12px;
  --transition: 0.2s ease;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --max-width: 1100px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- Typography ---- */
h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text);
}
h1 { font-size: 1.75rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.15rem; }

p { margin: 0.6em 0; }
b, strong { font-weight: 600; }

ul, ol {
  margin: 0.6em 0 0.6em 1.5em;
  padding: 0;
}
li { margin-bottom: 0.3em; }

/* ---- Links ---- */
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--color-primary-dark); }

/* ---- Images ---- */
img {
  max-width: 100%;
  height: auto;
  border: none;
  border-radius: var(--radius);
}
img.no-border { border: none; }
img.float-right { float: right; margin: 0 0 1em 1.5em; }
img.float-left { float: left; margin: 0 1.5em 1em 0; }

/* Content images: give them a consistent, attractive size instead of
   relying on arbitrary inline width="150px" attributes in the HTML */
#main img:not(.no-border) {
  width: 260px;
  height: 180px;
  object-fit: cover;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin: 0.5em 0;
}
#main img.float-right {
  float: right;
  margin: 0.5em 0 0.5em 1.5em;
}
#main img.float-left {
  float: left;
  margin: 0.5em 1.5em 0.5em 0;
}

/* Sidebar graphic image */
#sidebar img:not(.no-border) {
  width: 100%;
  max-width: 200px;
  height: auto;
  border-radius: var(--radius);
  border: none;
  margin-top: 1rem;
  object-fit: cover;
}

/* ---- Code / Blockquote ---- */
code {
  display: block;
  margin: 1em 0;
  padding: 1em;
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.9em;
  background: #f8fafc;
  border: 1px solid var(--color-border);
  border-left: 3px solid var(--color-primary);
  border-radius: var(--radius);
  overflow-x: auto;
  text-align: left;
}
blockquote {
  margin: 1.5em 0;
  padding: 1em 1.2em;
  background: #f0f7ff;
  border-left: 4px solid var(--color-primary);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--color-primary-dark);
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.1em;
  font-style: italic;
}

/* ---- Forms ---- */
form {
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
}
label {
  display: block;
  font-weight: 600;
  margin: 0.5em 0 0.25em;
}
input, textarea {
  width: 100%;
  padding: 0.6em 0.8em;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 0.95em;
  color: var(--color-text);
  background: var(--color-surface);
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(26,115,232,0.15);
}
textarea { min-height: 120px; resize: vertical; }
input.button {
  width: auto;
  padding: 0.6em 1.5em;
  font-weight: 600;
  background: var(--color-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}
input.button:hover {
  background: var(--color-primary-dark);
  transform: translateY(-1px);
}

/* ============================================
   LAYOUT
   ============================================ */

#wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  background: var(--color-surface);
  box-shadow: var(--shadow-lg);
  text-align: left;
}

/* ---- Header ---- */
#header {
  position: relative;
  background: linear-gradient(135deg, var(--color-header-from) 0%, var(--color-header-to) 100%);
  padding: 1.5rem 2rem 0;
  min-height: 80px;
}
#header h1#logo {
  position: relative;
  margin: 0;
  padding: 0;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
}
#header h1#logo .green { color: var(--color-accent); }
#header h2#slogan {
  position: relative;
  margin: 0.15em 0 0 0;
  font-size: 0.85rem;
  font-weight: 400;
  color: rgba(255,255,255,0.7);
  text-transform: none;
  letter-spacing: 0.5px;
}
#header br { display: none; }
#header h1#logo + br { display: none; }

/* Language switcher */
#header form.searchform {
  position: absolute;
  top: 1.2rem;
  right: 2rem;
  background: transparent;
  border: none;
  margin: 0;
  padding: 0;
}
#header form.searchform p {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
}
#header form.searchform a {
  display: inline-flex;
  border-radius: 4px;
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}
#header form.searchform a:hover {
  transform: scale(1.1);
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
#header form.searchform img {
  display: block;
  border-radius: 3px;
  border: 2px solid rgba(255,255,255,0.3);
}

/* Navigation tabs */
#header ul {
  display: flex;
  list-style: none;
  margin: 1.2rem 0 0;
  padding: 0;
  gap: 2px;
  position: relative;
  z-index: 10;
}
#header li {
  display: inline-block;
  margin: 0;
  padding: 0;
}
#header a {
  display: block;
  padding: 0.6em 1.2em;
  color: rgba(255,255,255,0.75);
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
  border-radius: var(--radius) var(--radius) 0 0;
  transition: background var(--transition), color var(--transition);
  background: transparent;
}
#header a span {
  display: inline;
  padding: 0;
  color: inherit;
  background: none;
}
#header a:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
#header a:hover span { color: #fff; }
#header a[style*="color:#000000"],
#header a[style*="color: #000000"] {
  background: rgba(255,255,255,0.15);
  color: #fff !important;
}
#header a[style*="color:#000000"] span,
#header a[style*="color: #000000"] span {
  color: #fff !important;
}

/* ---- Content area ---- */
#content-wrap {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 0;
  min-height: 400px;
}

/* Banner image */
#content-wrap > img:first-child {
  grid-column: 1 / -1;
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 0;
  border: none;
}

/* Main content */
#main {
  grid-column: 1;
  padding: 2rem;
  min-width: 0;
}

/* Rightbar: featured page image. Rendered as a full-width, centered,
   nicely-proportioned band below the main content. */
#rightbar {
  grid-column: 1 / -1;
  padding: 0 2rem 2rem;
  text-align: center;
}
#rightbar img {
  width: 100%;
  max-width: 480px;
  height: 220px;
  object-fit: cover;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

/* Sidebar */
#sidebar {
  grid-column: 2;
  padding: 1.5rem;
  background: #f8fafc;
  border-left: 1px solid var(--color-border);
}
#sidebar h1 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-text-light);
  margin-bottom: 0.8rem;
}
#sidebar ul.sidemenu {
  list-style: none;
  margin: 0;
  padding: 0;
}
#sidebar ul.sidemenu li {
  margin-bottom: 4px;
  border: none;
}
#sidebar ul.sidemenu a {
  display: block;
  padding: 0.55em 0.8em;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--color-text);
  text-decoration: none;
  background: var(--color-surface);
  border-radius: var(--radius);
  border-left: 3px solid transparent;
  transition: all var(--transition);
  box-shadow: var(--shadow-sm);
  min-height: auto;
}
#sidebar ul.sidemenu a p {
  margin: 0;
  padding: 0;
  line-height: 1.3 !important;
  font-style: normal !important;
}
#sidebar ul.sidemenu a[style*="background: #FCFFCD"],
#sidebar ul.sidemenu a[style*="background:#FCFFCD"] {
  background: var(--color-surface) !important;
  font-style: normal !important;
}
#sidebar ul.sidemenu a:hover {
  background: var(--color-surface);
  color: var(--color-primary);
  border-left-color: var(--color-primary);
  box-shadow: var(--shadow-md);
  transform: translateX(2px);
}
#sidebar ul.sidemenu a[style*="background: #84BEE6"],
#sidebar ul.sidemenu a[style*="background:#84BEE6"] {
  background: var(--color-primary) !important;
  color: #fff !important;
  border-left-color: var(--color-primary-dark) !important;
}
#sidebar ul.sidemenu a[style*="background: #84BEE6"]:hover,
#sidebar ul.sidemenu a[style*="background:#84BEE6"]:hover {
  background: var(--color-primary-dark) !important;
}

/* Sidebar graphic */
#sidebar img:not(.no-border) {
  width: 100%;
  border-radius: var(--radius);
  margin-top: 1rem;
  border: none;
}

/* ---- Footer ---- */
#footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 2rem;
  background: var(--color-footer-bg);
  color: rgba(255,255,255,0.6);
  font-size: 0.85rem;
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  height: auto;
  min-height: auto;
}
#footer a {
  color: rgba(255,255,255,0.8);
  font-weight: 500;
  transition: color var(--transition);
}
#footer a:hover { color: #fff; }
#footer .footer-left,
#footer .footer-right {
  float: none;
  width: auto;
}
.align-left { text-align: left; }
.align-right { text-align: right; }

/* ---- Utility ---- */
.clear { clear: both; }
.green { color: var(--color-accent); }
.gray { color: var(--color-text-light); }
.red { color: #dc2626; }

/* ---- Content image styling ---- */

/* ---- Post footer (if used) ---- */
.post-footer {
  background: #f8fafc;
  padding: 0.8em 1em;
  margin: 1.5em 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-size: 0.9em;
  display: flex;
  gap: 1.5em;
  flex-wrap: wrap;
}
.post-footer .date,
.post-footer .comments,
.post-footer .readmore {
  padding-left: 1.5em;
  margin: 0;
}
.post-footer .date { background: none; padding-left: 1.5em; }
.post-footer .comments { background: none; padding-left: 1.5em; }
.post-footer .readmore { background: none; padding-left: 1.5em; }

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

@media (max-width: 768px) {
  #header {
    padding: 1rem 1.2rem 0;
  }
  #header h1#logo {
    font-size: 1.5rem;
  }
  #header form.searchform {
    position: relative;
    top: auto;
    right: auto;
    margin-top: 0.5rem;
  }
  #header ul {
    flex-wrap: wrap;
    gap: 2px;
    margin-top: 0.8rem;
  }
  #header a {
    padding: 0.5em 0.8em;
    font-size: 0.8rem;
  }

  #content-wrap {
    grid-template-columns: 1fr;
  }
  #content-wrap > img:first-child {
    height: 140px;
  }
  #main {
    grid-column: 1;
    padding: 1.5rem;
  }
  #sidebar {
    grid-column: 1;
    border-left: none;
    border-top: 1px solid var(--color-border);
    padding: 1.5rem;
  }
  #rightbar {
    padding: 0 1.5rem 1.5rem;
  }
  #rightbar img {
    width: 100%;
    max-width: 100%;
    height: auto;
  }
  #footer {
    flex-direction: column;
    gap: 0.5em;
    text-align: center;
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  #header h1#logo {
    font-size: 1.25rem;
  }
  #header h2#slogan {
    font-size: 0.75rem;
  }
  #main {
    padding: 1rem;
  }
  #main h1 {
    font-size: 1.3rem;
  }
  #sidebar {
    padding: 1rem;
  }
}
