 
/* =========================================
   1. GLOBAL RESET
========================================= */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    width: 100%;
    min-height: 100%;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #f8f9fa;
    margin: 0;
    padding: 125px 0 0;
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;

    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    overflow-wrap: anywhere;
}

/* =========================================
   2. FIXED HEADER
========================================= */
    header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    min-width: 0;
    padding: 10px 24px;

    color: #ffffff;

    border-bottom: 3px solid #FF8C00;
    box-shadow: 0 4px 15px rgba(7, 25, 82, 0.3);

    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    
    
    background: linear-gradient(
        110deg,
        #071952 0%,
        #0B60B0 65%,
        #1595D4 100%
    ) !important;

    border-bottom: 3px solid #FF8C00 !important;
    box-shadow: 0 4px 15px rgba(7, 25, 82, 0.3);
}



/* Logo and site title */
.logo-section {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.logo-section img {
    display: block;
    width: 100px;
    height: 100px;
    object-fit: contain;
    flex-shrink: 0;

    border-radius: 20%;
    border: 2px solid white;
}

.header-text {
    min-width: 0;
}

.header-text h1 {
    margin: 0;
    font-size: clamp(22px, 2.8vw, 38px);
    line-height: 1.2;
    letter-spacing: 0.5px;
    overflow-wrap: anywhere;
}

.header-text p {
    margin: 5px 0 0;
    font-size: clamp(12px, 1.2vw, 16px);
    line-height: 1.4;
    font-style: italic;
}

/* Header contact details */
.contact {
    text-align: right;
    font-size: clamp(12px, 1.2vw, 16px);
    line-height: 1.5;
    padding: 5px;
    margin: 0;
    min-width: 0;
    overflow-wrap: anywhere;
}

/* Logout button */
.logout-btn {
    display: inline-block;
    width: auto;
    flex-shrink: 0;

    background: red;
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 20px;

    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
}

.logout-btn:hover {
    background: #005f00;
    color: white;
    transform: scale(1.03);
}


/* =========================================
   3. MAIN CONTAINER AND PANELS
========================================= */
.container {
    display: flex;
    align-items: flex-start;
    gap: 20px;

    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 15px;
}

.left-panel,
.right-panel {
    min-width: 0;
    background: white;
    padding: 12px;

    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.left-panel {
    flex: 0 0 280px;
    max-width: 100%;
}

.right-panel {
    flex: 1 1 0;
    width: 0;
}

/* =========================================
   4. GOALS SECTION
========================================= */
.goals-section {
    background: #f8f8ff;
    padding: 12px;
    border-radius: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.goals-section h3 {
    color: #0056b3;
    margin: 0 0 15px;
    font-size: clamp(18px, 2vw, 24px);
    font-weight: 700;
}

.goals-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    justify-items: stretch;
}

.goal-card {
    width: 100%;
    min-width: 0;

    background: navy;
    color: white;
    padding: 5px;
    border-radius: 12px;

    font-weight: 600;
    font-size: clamp(13px, 1.3vw, 18px);

    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.goal-card:hover {
    background: navy;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.goal-card a {
    display: block;
    text-align: center;
    text-decoration: none;
    color: white;
    font-weight: bold;

    background: navy;
    padding: 10px 8px;
    border-radius: 8px;
    line-height: 1.4;
    overflow-wrap: anywhere;

    transition: background 0.3s ease;
}

.goal-card a:hover {
    background: #e65c00;
}

/* =========================================
   5. SECTION TITLES
========================================= */
.section-title {
    text-align: center;
    margin: 0 0 20px;
    animation: fadeIn 1s ease-in-out;
}

.section-title h2 {
    background: linear-gradient(90deg, #001f5c, #ff6600);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;

    font-size: clamp(21px, 2.5vw, 30px);
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
    position: relative;
    display: inline-block;
    overflow-wrap: anywhere;
}

.section-title h2::after {
    content: "";
    display: block;
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, #ff6600, #001f5c);
    margin: 8px auto 0;
    border-radius: 2px;
}

.section-title p {
    color: #333;
    font-size: clamp(13px, 1.5vw, 16px);
    line-height: 1.5;
    margin: 8px 0 0;
    font-style: italic;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   6. RESPONSIVE TABLES
========================================= */

/*
   Put wide tables inside a wrapper:
   <div class="table-responsive">
       <table>...</table>
   </div>
*/
.table-responsive {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 15px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;

    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Keep data readable on laptops */
th {
    background: linear-gradient(90deg, #001f5c, #003399);
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

th,
td {
    padding: 10px;
    border: 1px solid #ddd;
    text-align: left;
    vertical-align: middle;
    font-size: 16px;
    line-height: 1.5;
}

td {
    color: #333333;
}

td a {
    display: inline-block;
    max-width: 100%;
    color: #002a7d;
    text-decoration: none;
    overflow-wrap: anywhere;
    white-space: normal;
}

td a:hover {
    color: #ff6600;
    text-decoration: underline;
}

tr:nth-child(even) {
    background-color: #f2f6ff;
}

tr:nth-child(odd) {
    background-color: #ffffff;
}

tr:hover {
    background-color: #e0ebff;
}

tr.checked-row {
    background-color: #d4edda;
}

td.date,
th.date {
    white-space: normal;
    min-width: 100px;
}

/* Action links */
a.btn {
    display: inline-block;
    width: auto;
    min-width: 60px;
    text-align: center;
    padding: 7px 10px;
    margin: 2px;

    border-radius: 5px;
    text-decoration: none;
    color: white;
    font-size: 13px;
}

a.edit-btn {
    background-color: #28a745;
}

a.edit-btn:hover {
    background-color: #1e7e34;
}

a.delete-btn {
    background-color: #dc3545;
}

a.delete-btn:hover {
    background-color: #c82333;
}

/* =========================================
   7. INPUTS, SELECTS AND BUTTONS
========================================= */
input,
select,
button {
    max-width: 100%;
    font-family: inherit;
    font-size: 16px;
    border-radius: 5px;
}

input,
select {
    width: 100%;
    min-width: 0;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
}

input {
    background: white;
    color: #222;
}

input:focus,
select:focus {
    outline: 2px solid #0056b3;
    outline-offset: 1px;
}

button {
    padding: 10px 14px;
    margin-bottom: 10px;
    background: #002a7d;
    color: white;
    border: none;
    cursor: pointer;
}

button:hover {
    background: #0056b3;
}

/* Select dropdown */
select {
    font-weight: bold;
    text-align: center;
    font-size: 16px;
    padding: 10px;

    border: 2px solid #ccc;
    color: white;
    background: green;
}

option {
    font-weight: normal;
    color: white;
    background: green;
}

/* General link button */
.btn-link {
    display: inline-block;
    max-width: 100%;
    background: green;
    color: white;

    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 16px;
    line-height: 1.4;

    transition: background 0.3s, transform 0.2s;
}

.btn-link:hover {
    background: #ff6600;
    transform: translateY(-1px);
    color: white;
}

/* =========================================
   8. FOOTER
========================================= */
footer {
    width: 100%;
     background: linear-gradient(
        110deg,
        #071952 0%,
        #0B60B0 65%,
        #1595D4 100%
    ) !important;
    color: white;
    text-align: center;

    padding: 12px 10px;
    margin-top: 65px;
    position: relative;
}

footer .social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

footer .social-links a {
    color: white;
    margin: 0 5px;
    text-decoration: none;
    font-size: 22px;
    transition: color 0.3s;
}

footer .social-links a:hover {
    color: #ffd700;
}

/* =========================================
   9. LAPTOPS AND SMALL DESKTOPS
========================================= */
@media screen and (max-width: 1024px) {
    header {
        padding: 10px 16px;
        gap: 12px;
    }

    .logo-section {
        gap: 10px;
    }

    .logo-section img {
        width: 75px;
        height: 65px;
    }

    .left-panel {
        flex-basis: 240px;
    }

    .container {
        gap: 15px;
        padding: 12px;
    }

    th,
    td {
        padding: 8px;
        font-size: 15px;
    }
}

/* =========================================
   10. TABLETS AND SMALL SCREENS
========================================= */
@media screen and (max-width: 800px) {
    body {
        padding-top: 0;
    }

    header {
        position: relative;
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 12px 16px;
    }

    .logo-section {
        justify-content: center;
        text-align: center;
    }

    .logo-section img {
        width: 65px;
        height: 60px;
    }

    .header-text h1 {
        font-size: clamp(21px, 4vw, 30px);
    }

    .header-text p {
        font-size: 13px;
    }

    .contact {
        text-align: center;
        padding: 0;
        font-size: 14px;
    }

    .logout-btn {
        display: block;
        width: 100%;
        margin: 0;
        padding: 10px 14px;
        font-size: 16px;
        border-radius: 8px;
    }

    .container {
        flex-direction: column;
        width: 100%;
        gap: 15px;
        padding: 12px;
    }

    .left-panel,
    .right-panel {
        width: 100%;
        max-width: 100%;
        flex: 1 1 auto;
    }

    .goals-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .goal-card {
        font-size: 15px;
    }

    .table-responsive table {
        min-width: 600px;
    }
}

/* =========================================
   11. MOBILE PHONES
========================================= */
@media screen and (max-width: 480px) {
    .container {
        padding: 8px;
        padding-top: 140px;
        gap: 12px;
    }

    .left-panel,
    .right-panel {
        padding: 10px;
        border-radius: 8px;
    }

    .logo-section {
        gap: 9px;
    }

    .logo-section img {
        width: 55px;
        height: 52px;
    }

    .header-text h1 {
        font-size: clamp(19px, 5vw, 25px);
        letter-spacing: 0;
    }

    .header-text p {
        font-size: 12px;
    }

    .contact {
        font-size: 13px;
        line-height: 1.6;
    }

    .goals-section {
        padding: 10px;
    }

    .goals-section h3 {
        font-size: 19px;
    }

    .goals-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .goal-card {
        padding: 4px;
        font-size: 13px;
        border-radius: 8px;
    }

    .goal-card a {
        padding: 9px 5px;
    }

    .section-title {
        margin-bottom: 15px;
    }

    .section-title h2 {
        font-size: 21px;
    }

    .section-title p {
        font-size: 13px;
    }

    th,
    td {
        padding: 7px;
        font-size: 14px;
    }

    .table-responsive table {
        min-width: 560px;
    }

    a.btn {
        min-width: 54px;
        padding: 7px 8px;
        font-size: 12px;
    }

    input,
    select,
    button {
        font-size: 16px;
    }

    .btn-link {
        font-size: 14px;
        padding: 8px 10px;
    }

    footer {
        font-size: 13px;
        padding: 12px 8px;
    }

    footer .social-links {
        gap: 8px;
    }

    footer .social-links a {
        font-size: 20px;
        margin: 0 3px;
    }
}

/* =========================================
   12. EXTRA-SMALL MOBILE PHONES
========================================= */
@media screen and (max-width: 320px) {
    header {
        padding: 10px;
    }

    .logo-section img {
        width: 45px;
        height: 45px;
    }

    .header-text h1 {
        font-size: 18px;
    }

    .header-text p {
        font-size: 11px;
    }

    .container {
        padding: 5px;
    }

    .left-panel,
    .right-panel {
        padding: 7px;
    }

    .goals-grid {
        grid-template-columns: 1fr;
    }

    .goal-card {
        font-size: 14px;
    }

    .section-title h2 {
        font-size: 19px;
    }

    th,
    td {
        padding: 6px;
        font-size: 12px;
    }

    .table-responsive table {
        min-width: 520px;
    }
}

/* =========================================
   13. ACCESSIBILITY
========================================= */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

.responsive-divider {
    width: 100%;
    max-width: 900px;
    height: 3px;
    margin: 15px auto;
    background: linear-gradient(90deg, #001f5c, #ff6600);
    border-radius: 10px;
    position: relative;
}

.responsive-divider::after {
    content: "";
    display: block;
    width: clamp(40px, 12%, 100px);
    height: 5px;
    margin: auto;
    background: #ff6600;
    border-radius: 10px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .responsive-divider {
        width: 95%;
        height: 2px;
        margin: 12px auto;
    }

    .responsive-divider::after {
        height: 4px;
    }
}


/* Sidebar container */
.left-panel {
    flex: 0 0 280px;
    width: 280px;
    max-width: 100%;
    min-width: 0;
    padding: 12px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.10);
}

/* Menu section */
.goals-section {
    padding: 5px;
    background: #ffffff;
    border-radius: 10px;
}

/* Section heading */
.menu-heading {
    margin: 8px 0 12px;
    padding: 10px 12px;
    color: #ffffff;
    background: linear-gradient(90deg, #001f5c, #003399);
    border-left: 4px solid #ff6600;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 700;
}

/* Menu grid */
.goals-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 7px;
    width: 100%;
}

/* Menu links */
.goal-card {
    display: block;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    background: transparent;
    border-radius: 7px;
    box-shadow: none;
    font-size: 15px;
    font-weight: 500;
    transition: background 0.2s ease, transform 0.2s ease;
}

/* Anchor fills the menu row */
.goal-card a,
a.goal-card {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    min-width: 0;
    padding: 11px 12px;

    color: #001f5c;
    background: #f3f6fc;
    border: 1px solid #e4eaf5;
    border-radius: 7px;

    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    overflow-wrap: anywhere;

    transition: background 0.2s ease,
                color 0.2s ease,
                border-color 0.2s ease;
}

/* Icons */
.menu-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    width: 28px;
    font-size: 19px;
}

/* Hover and keyboard focus */
.goal-card a:hover,
a.goal-card:hover {
    color: #ffffff;
    background: linear-gradient(90deg, #001f5c, #ff6600);
    border-color: #ff6600;
}

.goal-card a:focus-visible,
a.goal-card:focus-visible {
    outline: 3px solid #ff6600;
    outline-offset: 2px;
}

/* Section divider */
.responsive-divider {
    width: 100%;
    height: 2px;
    margin: 16px 0;
    background: linear-gradient(90deg, #001f5c, #ff6600);
    border-radius: 10px;
}

/* Tablet */
@media (max-width: 800px) {
    .left-panel {
        width: 100%;
        flex: 1 1 100%;
        padding: 10px;
    }

    .goals-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .menu-heading {
        font-size: 16px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .left-panel {
        padding: 8px;
    }

    .goals-section {
        padding: 3px;
    }

    .goals-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .goal-card a,
    a.goal-card {
        gap: 7px;
        padding: 10px 7px;
        font-size: 13px;
    }

    .menu-icon {
        flex-basis: 22px;
        width: 22px;
        font-size: 17px;
    }

    .menu-heading {
        margin: 8px 0 10px;
        padding: 9px 10px;
        font-size: 14px;
    }

    .responsive-divider {
        margin: 12px 0;
    }
}

/* Extra-small phones */
@media (max-width: 320px) {
    .goals-grid {
        grid-template-columns: 1fr;
    }

    .goal-card a,
    a.goal-card {
        padding: 10px;
        font-size: 14px;
    }
}
    
    
    
    
    
/* Header layout */
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    width: 100%;
    padding: 10px 24px;

    background: linear-gradient(90deg, #001f5c, #ff6600);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);

    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
}

/* Logo and title */
.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.logo-section img {
    width: 90px;
    height: 70px;
    object-fit: contain;
    border-radius: 20%;
    border: 2px solid white;
}

.header-text {
    min-width: 0;
}

.header-text h1 {
    margin: 0;
    font-size: clamp(20px, 2.5vw, 34px);
}

.header-text h1 a {
    color: white;
    text-decoration: none;
}

.header-text p {
    margin: 4px 0 0;
    color: white;
    font-size: clamp(11px, 1.2vw, 15px);
    line-height: 1.4;
}

/* Header buttons */
.header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-shrink: 0;
}

.logout-btn {
display: inline-block;
    width: auto;
    margin: 0;
    padding: 10px 16px;

    color: white;
    background: green;
    border: none;
    border-radius: 8px;

    font-size: 15px;
    font-weight: bold;
    text-decoration: none;
    white-space: nowrap;
}


/* Dropdown container */
.header-dropdown {
    position: relative;
}
@media (max-width: 768px) {
    .header-dropdown {
        position: absolute;
        left: 0;
        right: auto;
    }
}

/* Dropdown trigger */
.dropdown-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    width: auto;
    margin: 0;
    padding: 10px 15px;

    color: white;
    background: #001f5c;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 8px;

    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    white-space: nowrap;
}

.dropdown-btn:hover {
    background: #003399;
}

.dropdown-arrow {
    transition: transform 0.2s ease;
}

.dropdown-btn[aria-expanded="true"] .dropdown-arrow {
    transform: rotate(180deg);
}



.header-dropdown-menu.show {
    display: block;
}

.header-dropdown-menu a {
    display: block;
    padding: 11px 12px;

    color: #001f5c;
    font-size: 14px;
    line-height: 1.4;
    text-decoration: none;
    overflow-wrap: anywhere;
    border-radius: 6px;
}

.header-dropdown-menu a:hover,
.header-dropdown-menu a:focus-visible {
    color: white;
    background: linear-gradient(90deg, #001f5c, #ff6600);
}

/* Tablet and mobile */
@media screen and (max-width: 768px) {
    header {
        padding: 10px 12px;
        gap: 8px;
    }

    .logo-section {
        gap: 8px;
        flex: 1;
    }

    .logo-section img {
        width: 50px;
        height: 50px;
    }

    .header-text h1 {
        font-size: clamp(16px, 4vw, 24px);
    }

    .header-text p {
        font-size: 11px;
    }

    .header-actions {
        gap: 6px;
    }

    .dropdown-btn {
        padding: 10px;
        font-size: 13px;
    }

    .logout-btn {
        padding: 10px;
        font-size: 12px;
    }

    .header-dropdown-menu {
        right: 0;
        width: 220px;
    }
}

/* Extra-small mobile */
@media screen and (max-width: 380px) {
    header {
        padding: 8px;
        gap: 5px;
    }

    .logo-section {
        gap: 5px;
    }

    .logo-section img {
        width: 40px;
        height: 42px;
    }

    .header-text h1 {
        font-size: 15px;
    }
    .header-text p {
        font-size: 9px;
    }

    .header-actions {
        gap: 4px;
    }

    .dropdown-btn {
        padding: 9px 7px;
        font-size: 12px;
    }

    .logout-btn {
        padding: 9px 7px;
        font-size: 10px;
    }
}

/* Force header text sizes on mobile */
@media screen and (max-width: 768px) {
    .header-text h1 {
        font-size: 35px !important;
        line-height: 1.2;
    }

    .header-text h1 a {
        font-size: inherit !important;
    }

    .header-text p {
        font-size: 13px !important;
    }
}

/* Extra-small mobile screens */
@media screen and (max-width: 380px) {
    .header-text h1 {
        font-size: 22px !important;
    }

    .header-text p {
        font-size: 11px !important;
    }
}
























