﻿/* ===========================
   HERO
   =========================== */
.rules-hero {
    position: relative;
    height: 330px; /* medium */
    background: url('/rules/images/hero.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.rules-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        rgba(0, 0, 0, 0.45),
        rgba(0, 0, 0, 0.65)
    );
}

.rules-hero-content {
    position: relative;
    z-index: 2;
    color: #fff;
    padding: 1rem;
}

.rules-hero-content h1 {
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.rules-hero-sub {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 1rem;
}

/* Search bar */
.rules-hero-search {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.2rem;
}

.rules-hero-search input {
    width: 300px;
    padding: 0.55rem;
    border-radius: 6px;
    border: none;
}

.rules-hero-search button {
    padding: 0.55rem 1rem;
    background: #1e8f43;
    border: none;
    border-radius: 6px;
    color: white;
    cursor: pointer;
    font-weight: 600;
}

.rules-hero-scroll {
    cursor: pointer;
    font-size: 1rem;
    opacity: 0.85;
}

/* ===========================
   ZONE GRID
   =========================== */
.rules-zone-section {
    padding: 2.5rem 1rem;
}

.rules-section-title {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.9rem;
}

.rules-zone-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
    max-width: 1200px;
    margin: 0 auto;
}

.rules-zone-card {
    background: #fff;
    border: 1px solid #e4e4e4;
    border-radius: 10px;
    padding: 1.25rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: transform 0.15s ease;
}

.rules-zone-card:hover {
    transform: translateY(-3px);
}

.rules-zone-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.4rem;
}

.rules-zone-card p {
    font-size: 0.95rem;
    opacity: 0.8;
}

/* ===========================
   RULE VIEWER
   =========================== */
.hidden {
    display: none;
}

.rules-viewer-section {
    padding: 2rem 1rem;
    max-width: 900px;
    margin: 0 auto;
}

.rules-viewer-back {
    cursor: pointer;
    margin-bottom: 1rem;
    color: #1e8f43;
    font-weight: 600;
}

.rules-viewer-title {
    font-size: 2rem;
    margin-bottom: 1rem;
}

/* Zone-specific search */
.rules-zone-search {
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: flex-start;
}

.rules-zone-search input {
    width: 100%;
    padding: 0.6rem;
    border-radius: 6px;
    border: 1px solid #cfcfcf;
}

/* Category cards */
.rule-category {
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.rule-category-header {
    padding: 1rem;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: 600;
    border-bottom: 1px solid #eee;
}

.rule-category-content {
    padding: 1rem 1.25rem;
    display: none;
}

.rule-item {
    margin-bottom: 0.75rem;
    font-size: 0.98rem;
    line-height: 1.4rem;
}
.rules-zone-card h3,
.rules-zone-card p {
    color: #000 !important;
    text-shadow: 0 1px 2px rgba(255,255,255,0.2);
}
/* Improve card look */
.rules-zone-grid {
    max-width: 1100px;
    margin: 0 auto;
    gap: 1.5rem;
}

.rules-zone-card {
    background: #fff;
    border-radius: 14px;
    padding: 1.4rem 1.6rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    transition: transform .18s ease, box-shadow .18s ease;
}

.rules-zone-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
}

.rules-zone-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: .4rem;
}

.rules-zone-card p {
    color: #555 !important;
    font-size: .95rem;
}
/* Fix invisible text in rule viewer */
.rule-category,
.rule-category * {
    color: #111 !important;
}

/* Improve headers */
.rule-category-header {
    color: #000 !important;
    background: #e9eef5;
    border-radius: 8px 8px 0 0;
    font-weight: 600;
}

/* Improve body text */
.rule-category-content {
    color: #222 !important;
}

/* Fix water cards too */
.rule-water-card,
.rule-water-card * {
    color: #111 !important;
}
/* Waterbody selector cards */
.waterbody-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.waterbody-card {
    background: #ffffff;
    padding: 0.7rem 1rem;
    border-radius: 10px;
    border: 1px solid #dcdcdc;
    cursor: pointer;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    transition: all 0.18s ease;
    user-select: none;
}

.waterbody-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.waterbody-card.active {
    background: #1e8f43;
    color: white !important;
    border-color: #1e8f43;
}
/* ===========================================
   WATERBODY SELECTOR CARDS (Option B)
=========================================== */

.waterbody-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0 1.5rem 0;
}

.waterbody-card {
    background: #fff;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    border: 1px solid #d0d0d0;
    cursor: pointer;
    font-weight: 500;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    transition: all 0.18s ease;
    user-select: none;
    font-size: 0.95rem;
}

.waterbody-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.waterbody-card.active {
    background: #1e8f43;
    border-color: #1e8f43;
    color: #fff !important;
}
/* ============================================================
   WATERBODY SELECTOR CARDS — STYLE B (Wide, Clean Buttons)
============================================================ */

.waterbody-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0 1.25rem 0;
}

.waterbody-card {
    background: #f4f7fa;                     /* visible light background */
    border: 1px solid #d1d9e0;               /* soft border */
    color: #1c1c1c;                          /* readable dark text */
    padding: 0.65rem 1.1rem;                 /* comfortable touch target */
    border-radius: 8px;                      /* smooth rounded corners */
    font-size: 0.95rem;
    font-weight: 500;
    min-width: 220px;                        /* wide, clear buttons */
    text-align: center;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    transition: all 0.15s ease;
}

.waterbody-card:hover {
    background: #e7eef5;
    transform: translateY(-2px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.12);
}

.waterbody-card.active {
    background: #1e8f43 !important;          /* your brand green */
    color: #ffffff !important;
    border-color: #1e8f43;
    box-shadow: 0 3px 10px rgba(0,0,0,0.18);
}
.rule-water-card h4 {
    color: #000 !important;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.rule-water-card h5 {
    color: #222 !important;
    margin-top: 0.6rem;
}

.rule-water-card li,
.rule-water-card p {
    color: #333 !important;
    line-height: 1.45;
}
/* Make waterbody rule text readable */
.rule-water-card,
.rule-water-card * {
    color: #1a1a1a !important;
}
/* Make waterbody rule text readable on dark background */
.rule-water-card,
.rule-water-card * {
    color: #f8f8f8 !important;
}

.rule-water-card h4 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: #ffffff !important;
}

.rule-water-card h5 {
    margin-top: 0.65rem;
    margin-bottom: 0.25rem;
    font-size: 1.05rem;
    color: #e6e6e6 !important;
}

.rule-water-card li {
    color: #dddddd !important;
    line-height: 1.5rem;
    margin-left: 1rem;
}


