/* =================================================================
   Global Styles & Variables
   ================================================================= */
:root {
  /* Dynamic CSS variables are loaded from manifest.json via layout.tpl */
  /* Static layout variables */
  --border-radius: 8px;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 8px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 16px rgba(0,0,0,0.15);
}

body {
    font-family: var(--font-family, 'Inter', sans-serif);
    color: var(--text-color);
    background-color: var(--background-light-color);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--text-color);
}

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

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

/* =================================================================
   Custom Bootstrap Components & Utilities
   ================================================================= */
.bg-primary-custom { background-color: var(--primary-color) !important; }
.text-primary-custom { color: var(--primary-color) !important; }
.btn-primary-custom {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
  transition: all 0.3s ease;
}
.btn-primary-custom:hover {
  background-color: var(--primary-color-hover);
  border-color: var(--primary-color-hover);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.bg-secondary-custom { background-color: var(--secondary-color) !important; }
.bg-background-orange-color { background-color: var(--background-orange-color) !important; }

/* =================================================================
   Header
   ================================================================= */
header .navbar-brand img {
    max-height: 50px;
}
header .bg-primary-custom .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    transition: background-color 0.3s ease;
}
header .bg-primary-custom .nav-link:hover {
    background-color: rgba(255,255,255,0.1);
    text-decoration: none;
}
header .bg-secondary-custom {
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
header .breadcrumb {
    font-size: 0.9rem;
}
header .breadcrumb a {
    text-decoration: none;
}
header .breadcrumb a:hover {
    text-decoration: underline;
}

/* =================================================================
   Main Content & Cards
   ================================================================= */
.card {
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    border-radius: 0.5rem;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

.card-title {
    color: var(--primary-color);
}

.card a {
    text-decoration: none;
}

.card-img-top {
    border-bottom: 1px solid var(--border-color);
    width: auto;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* =================================================================
   Specific Sections
   ================================================================= */
.hero-section {
    position: relative;
    background-size: cover;
    background-position: center;
    color: white;
    padding: 6rem 0;
    border-radius: 0.5rem;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5));
    border-radius: 0.5rem;
}

.hero-section .container {
    position: relative;
    z-index: 1;
}

.hero-section h1 {
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.blog-content img,
.company-content img,
.page-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.25rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

/* =================================================================
   Footer
   ================================================================= */
footer {
    background-color: var(--footer-background-color);
    color: var(--footer-text-color);
}
footer h5 {
    color: var(--footer-text-color);
    font-weight: 600;
    margin-bottom: 1rem;
}
footer a {
    color: var(--footer-text-color);
    opacity: 0.8;
}
footer a:hover {
    color: var(--footer-text-color);
    opacity: 1;
    text-decoration: underline;
}
footer .border-top {
    border-color: rgba(255,255,255,0.1) !important;
}

/* =================================================================
   Forms
   ================================================================= */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem var(--background-overlay-color);
}
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem var(--background-overlay-color);
}
.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Bootstrap button overrides */
.btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: white !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: var(--primary-color-hover) !important;
    border-color: var(--primary-color-hover) !important;
    color: white !important;
}

.btn-outline-primary {
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    background-color: transparent !important;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: white !important;
}

.btn-secondary {
    background-color: var(--secondary-color) !important;
    border-color: var(--secondary-color) !important;
}

.btn-outline-secondary {
    color: var(--secondary-color) !important;
    border-color: var(--secondary-color) !important;
}

.btn-outline-secondary:hover {
    background-color: var(--secondary-color) !important;
    border-color: var(--secondary-color) !important;
}

/* Bootstrap Nav Pills overrides - requires !important */
.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
    background-color: var(--primary-color) !important;
    color: var(--text-inverse-color) !important;
}

/* Bootstrap text color utilities - requires !important */
.text-primary {
    color: var(--primary-color) !important;
}

.text-secondary {
    color: var(--secondary-color) !important;
}

.text-success {
    color: var(--success-color) !important;
}

.text-danger {
    color: var(--danger-color) !important;
}

.text-warning {
    color: var(--warning-color) !important;
}

.text-info {
    color: var(--info-color) !important;
}
