* {
    box-sizing: border-box;
}

/* Global Accessibility Styles */
:focus {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* Skip Link - Hidden but accessible for keyboard users */
.skip-link {
    position: absolute;
    top: -9999px;
    left: -9999px;
    display: block;
    background-color: #000;
    color: #fff;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    z-index: 10000;
}

.skip-link:focus {
    top: 0;
    left: 0;
}

.screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    height: 1px;
    overflow: hidden;
    position: absolute;
    width: 1px;
    word-wrap: normal;
}

.screen-reader-text:focus {
    background-color: #f1e05a;
    clip: auto;
    color: #000;
    display: block;
    font-size: 1em;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    line-height: 1.6;
    transition: overflow 0.3s ease;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.menu-open {
    overflow: hidden;
}

/* Performance: Optimize text rendering and prevent FOUT */
html {
    font-display: swap;
}

/* Performance: Optimize images and reduce paint invalidation */
img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Performance: Optimize form inputs */
input,
textarea,
select,
button {
    font-family: inherit;
    font-size: inherit;
}

/* Entry Content Styles */
.entry-content {
    font-size: 1rem;
    line-height: 1.7;
    color: #333;
    margin-bottom: 2rem;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
    color: #222;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.3;
}

.entry-content h1 { font-size: 2.25rem; }
.entry-content h2 { font-size: 1.875rem; }
.entry-content h3 { font-size: 1.5rem; }
.entry-content h4 { font-size: 1.25rem; }
.entry-content h5 { font-size: 1.125rem; }
.entry-content h6 { font-size: 1rem; }

.entry-content p {
    margin-bottom: 1.5rem;
    color: #444;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.entry-content li {
    margin-bottom: 0.5rem;
    color: #444;
}

.entry-content blockquote {
    border-left: 4px solid #007cba;
    padding-left: 1rem;
    margin: 2rem 0;
    font-style: italic;
    color: #555;
    background-color: #f8f9fa;
    padding: 1rem 1.5rem;
    border-radius: 4px;
}

.entry-content a {
    color: #007cba;
    text-decoration: none;
    transition: color 0.3s ease;
}

.entry-content a:hover {
    color: #005a87;
    text-decoration: underline;
}

.entry-content a:focus,
.entry-content a:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
    color: #005a87;
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 1rem 0;
}

.entry-content .wp-block-image {
    margin: 2rem 0;
}

/* Header Styles */
.header {
    position: relative;
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
    padding: 1rem 0;
    transition: padding 0.3s ease, box-shadow 0.3s ease;
}

.header.header-sticky {
    padding: 0.5rem 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #333;
}

.logo img {
    margin-right: 0.5rem;
}

.logo-text .logo-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0;
}

.logo-text .logo-sub-title {
    font-size: 0.9rem;
    color: #666;
    margin-top: -10px;
    letter-spacing: 0.3rem;
    text-transform: uppercase;
}

.waviy {
    display: inline-block;
}

.waviy span {
    display: inline-block;
    animation: waviy 2s infinite;
    animation-delay: calc(.1s * var(--i));
}

@keyframes waviy {
    0%, 40%, 100% {
        transform: translateY(0);
    }
    20% {
        transform: translateY(-10px);
    }
}

/* Primary Navigation */
.primary-navigation {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.primary-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.primary-menu-list li {
    position: relative;
    margin: 0 1rem;
}

.primary-menu-list li a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

.primary-menu-list li a:hover,
.primary-menu-list li a.active {
    color: #007cba;
    border-bottom-color: #007cba;
}

.primary-menu-list li a:focus,
.primary-menu-list li a:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: 2px;
    color: #007cba;
    border-bottom-color: #007cba;
}

.primary-menu-list li.current-menu-item > a,
.primary-menu-list li.current-menu-parent > a {
    color: #007cba;
    border-bottom-color: #007cba;
    font-weight: 600;
}

/* Dropdown */
.dropdown,
.sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fff;
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.primary-menu-list li:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown li,
.sub-menu li {
    margin: 0;
    list-style: none;
}

.dropdown li a,
.sub-menu li a {
    display: block;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #eee;
    transition: all 0.3s ease;
    line-height: 1.5;
}

.dropdown li a:hover,
.sub-menu li a:hover {
    background-color: #f0f7ff;
    padding-left: 1.75rem;
    color: #007cba;
}

.dropdown li a:focus,
.dropdown li a:focus-visible,
.sub-menu li a:focus,
.sub-menu li a:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: -2px;
    background-color: #f0f7ff;
    color: #007cba;
}

.dropdown li.current-menu-item > a,
.sub-menu li.current-menu-item > a {
    background-color: #f0f7ff;
    color: #007cba;
    font-weight: 600;
}

.dropdown,
.sub-menu {
    transition: all 0.4s ease;
}

.hover-ver2 {
    position: relative;
}

.hover-ver2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background-color: #007cba;
    transform: scaleY(0);
    transition: transform 0.3s;
}

.hover-ver2:hover::before {
    transform: scaleY(1);
}

.dropdown li a i {
    margin-right: 0.5rem;
    width: 20px;
}

/* Megamenu */
.has-megamenu .megamenu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: #fff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s;
    z-index: 1000;
}

.has-megamenu:hover .megamenu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.megamenu-row {
    display: flex;
    padding: 2rem;
}

.col3 {
    flex: 1;
    padding: 0 1rem;
}

.col3 ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.col3 li {
    margin-bottom: 0.5rem;
}

.col3 li a {
    display: block;
    padding: 0.5rem 0;
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.col3 li a:hover {
    color: #007cba;
}

.col3 li a i {
    float: right;
    margin-top: 2px;
}

.megamenu-item-info b {
    color: #007cba;
    font-size: 1.1rem;
}

.mb-20 {
    margin-bottom: 2rem !important;
}

/* Nav Add */
.nav-add {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.nav-add li {
    margin-left: 1rem;
}

.nav-add .nav-link {
    color: #333;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s;
    padding: 0.5rem;
}

.nav-add .nav-link:hover {
    color: #007cba;
}

.nav-add .nav-link:focus,
.nav-add .nav-link:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: 2px;
    color: #007cba;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
    margin-left: auto;
}

.mobile-menu-toggle:hover {
    background-color: #f0f0f0;
    border-radius: 4px;
}

.mobile-menu-toggle:focus,
.mobile-menu-toggle:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: 2px;
    background-color: #f0f0f0;
    border-radius: 4px;
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-icon span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-icon span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-icon span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.hamburger-icon {
    width: 24px;
    height: 18px;
    position: relative;
    display: block;
}

.hamburger-icon span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #333;
    position: absolute;
    transition: all 0.3s;
}

.hamburger-icon span:nth-child(1) {
    top: 0;
}

.hamburger-icon span:nth-child(2) {
    top: 8px;
}

.hamburger-icon span:nth-child(3) {
    top: 16px;
}

/* Mobile Navigation */
.mobile-navigation {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
}

.mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-list li {
    margin: 0;
    border-bottom: 1px solid #e0e0e0;
}

.mobile-menu-list li a {
    display: block;
    padding: 1rem 1.25rem;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.mobile-menu-list li a:hover,
.mobile-menu-list li a.active {
    color: #007cba;
    background-color: #f0f7ff;
}

.mobile-menu-list li a:focus,
.mobile-menu-list li a:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: -2px;
    color: #007cba;
    background-color: #f0f7ff;
}

.mobile-menu-list li.current-menu-item > a,
.mobile-menu-list li.current-menu-parent > a {
    color: #007cba;
    background-color: #f0f7ff;
    font-weight: 600;
}

/* Chevron indicator for items with children */
.mobile-menu-list .menu-item-has-children > a::after {
    content: '▼';
    position: absolute;
    right: 1.25rem;
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}

.mobile-menu-list .menu-item-has-children.submenu-open > a::after {
    transform: rotate(180deg);
}

/* Mobile submenu styling */
.mobile-menu-list .sub-menu {
    position: static;
    background-color: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.mobile-menu-list .menu-item-has-children.submenu-open .sub-menu {
    max-height: 500px;
}

.mobile-menu-list .sub-menu li {
    border: none;
    border-top: 1px solid #f0f0f0;
}

.mobile-menu-list .sub-menu li a {
    padding-left: 2.5rem;
    font-weight: 400;
    font-size: 0.95rem;
    color: #555;
}

.mobile-menu-list .sub-menu li a:hover,
.mobile-menu-list .sub-menu li a.active {
    color: #007cba;
}

.mobile-menu-list .sub-menu li a:focus,
.mobile-menu-list .sub-menu li a:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: -2px;
    color: #007cba;
    background-color: #f0f0ff;
}

.nav-add-mobile {
    list-style: none;
    margin: 0;
    padding: 0;
    justify-content: center;
}

.nav-add-mobile li {
    margin: 0 0.5rem;
}

.nav-add-mobile .nav-link {
    color: #333;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s;
    padding: 0.5rem;
}

.nav-add-mobile .nav-link:hover {
    color: #007cba;
}

.nav-add-mobile .nav-link:focus,
.nav-add-mobile .nav-link:focus-visible {
    outline: 2px solid #007cba;
    outline-offset: 2px;
    color: #007cba;
}

/* Footer Styles */
.footer {
    background-color: #1a1a1a;
    color: #fff;
    padding: 0;
}

.footer-middle {
    background-color: #343b41;
}

.footer-bottom {
    background-color: #30353b;
    padding: 1rem 0;
}

.footer .logo img {
    filter: brightness(0) invert(1);
}

/* ==================================================
   WordPress Featured Images – Responsive Fix
================================================== */

/* Ensure all WP images stay inside their container */
.site-main img,
.wp-post-image,
.entry-content img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Prevent overflow caused by large intrinsic widths */
.entry-content,
.site-main {
  overflow-wrap: break-word;
}

/* Bootstrap compatibility */
.img-fluid,
.wp-post-image {
  max-width: 100%;
  height: auto;
}

/* Cookie Settings Button Styling */
.cookie-settings-btn {
  background-color: transparent;
  border: none;
  color: inherit;
  font-family: inherit;
  font-size: inherit;
  padding: 0;
  cursor: pointer;
  transition: color 0.3s ease;
}

.cookie-settings-btn:hover {
  color: #007cba;
}

.cookie-settings-btn:focus,
.cookie-settings-btn:focus-visible {
  outline: 2px solid #007cba;
  outline-offset: 2px;
}

/* CTA Section Styling */
.cta-section {
  background: linear-gradient(135deg, rgba(0, 124, 186, 0.05) 0%, rgba(0, 124, 186, 0.02) 100%);
  border-left: 4px solid #007cba;
  border-radius: 4px;
  padding: 2.5rem !important;
  margin-top: 3rem !important;
}

.cta-section h3 {
  color: #222;
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.cta-section .cta-description {
  color: #555;
  font-size: 1rem;
  line-height: 1.6;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.cta-section .btn {
  padding: 0.75rem 2rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.cta-section .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
}

/* Trust Indicators */
.trust-indicators {
  background-color: #f8f9fa;
  border-radius: 4px;
  padding: 2rem;
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.trust-indicators h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #222;
  margin-bottom: 1.5rem;
}

.trust-indicators ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.trust-indicators li {
  display: flex;
  align-items: flex-start;
  margin-bottom: 1rem;
  color: #555;
  font-size: 0.95rem;
  line-height: 1.5;
}

.trust-indicators li:last-child {
  margin-bottom: 0;
}

.trust-indicators li::before {
  content: '✓';
  color: #28a745;
  font-weight: bold;
  margin-right: 0.75rem;
  font-size: 1.25rem;
  flex-shrink: 0;
}

/* Contact Page Trust Signals */
.contact-reassurance {
  background-color: #f0f7ff;
  border-left: 3px solid #007cba;
  padding: 1.5rem;
  margin-top: 1.5rem;
  border-radius: 4px;
  font-size: 0.95rem;
  color: #444;
}

.contact-reassurance p {
  margin: 0.5rem 0;
  line-height: 1.6;
}

.contact-reassurance p:first-child {
  margin-top: 0;
}

.contact-reassurance p:last-child {
  margin-bottom: 0;
}

/* Service Page Value Points */
.service-value-points {
  background: #f9f9f9;
  padding: 2rem;
  margin: 2rem 0;
  border-radius: 4px;
  border-top: 3px solid #007cba;
}

.service-value-points h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #222;
  margin-bottom: 1.5rem;
}

.service-value-points ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.service-value-points li {
  display: flex;
  align-items: flex-start;
  margin-bottom: 0.75rem;
  color: #555;
  font-size: 0.95rem;
}

.service-value-points li::before {
  content: '•';
  color: #007cba;
  font-weight: bold;
  margin-right: 0.75rem;
  font-size: 1.5rem;
  line-height: 1;
  flex-shrink: 0;
}

/* Related Portfolio Section */
.related-portfolio {
  border-top: 1px solid #e0e0e0;
  padding-top: 3rem;
}

.related-portfolio h3 {
  color: #222;
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 2rem;
}

/* Related Services Section */
.related-services {
  background: #f8f9fa;
  border-radius: 4px;
  padding: 2rem;
  border-top: 3px solid #007cba;
}

.related-services h3 {
  color: #222;
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 2rem;
}

.related-services .service-item {
  background: #fff;
  border-radius: 4px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.related-services .service-item:hover {
  box-shadow: 0 4px 12px rgba(0, 124, 186, 0.15);
}

.related-services .service-thumbnail {
  margin-bottom: 1rem;
  text-align: center;
}

.related-services .service-thumbnail img {
  max-width: 80px;
  height: auto;
}

.related-services .service-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.related-services .service-content h4 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #222;
}

.related-services .service-content h4 a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.related-services .service-content h4 a:hover {
  color: #007cba;
}

.related-services .service-content p {
  font-size: 0.9rem;
  color: #666;
  line-height: 1.5;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.related-services .btn {
  align-self: flex-start;
}
