/**
 * Notice Frontend Styles - Minimal & Clean
 * @version 1.0.0
 */

/* ========== TICKER ========== */
.hp-notice-ticker-wrap {
    display: flex;
    background: #fff;
    border: 1px solid #ddd;
    overflow: hidden;
    height: 40px;
    align-items: center;
    margin: 15px 0;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.hp-ticker-label {
    background: #003d82;
    color: #fff;
    padding: 0 1rem;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

.hp-ticker-icon {
    font-size: 1rem;
}

.hp-ticker-content-box {
    flex: 1;
    overflow: hidden;
    height: 100%;
    min-width: 0;
}

.hp-ticker-items {
    display: flex;
    white-space: nowrap;
    height: 100%;
    animation: hp-ticker-scroll 15s linear infinite;
    align-items: center;
}

.hp-ticker-items:hover {
    animation-play-state: paused;
}

.hp-ticker-item {
    padding: 0 1rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
    height: 100%;
    border-right: 1px solid #eee;
}

.hp-ticker-link {
    color: #1f2937;
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 600;
    transition: color 0.2s;
}

.hp-ticker-link:hover {
    color: #003d82;
}

.hp-ticker-date {
    color: #6b7280;
    font-size: 0.7rem;
    font-weight: 500;
}

.hp-new-badge {
    background: #dc2626;
    color: #fff;
    font-size: 0.5rem;
    font-weight: 700;
    padding: 2px 4px;
    border-radius: 2px;
    letter-spacing: 0.3px;
}

.hp-ticker-view-all {
    padding: 0 1rem;
    color: #003d82;
    font-weight: 700;
    font-size: 0.75rem;
    text-decoration: none;
    border-left: 1px solid #ddd;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: all 0.2s;
    flex-shrink: 0;
    height: 100%;
}

.hp-ticker-view-all:hover {
    background: #f9fafb;
}

.hp-arrow {
    font-size: 1.1rem;
    transition: transform 0.2s;
}

.hp-ticker-view-all:hover .hp-arrow {
    transform: translateX(2px);
}

@keyframes hp-ticker-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ========== ARCHIVE ========== */
.hp-notices-archive {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
}

.hp-archive-header {
    margin-bottom: 1rem;
}

.hp-archive-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 0.25rem 0;
}

.hp-archive-subtitle {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 0;
}

/* ========== SEARCH & FILTERS ========== */
.hp-archive-controls-wrapper {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.hp-archive-controls {
    display: flex;
    gap: 0.75rem;
    align-items: stretch;
    flex-wrap: wrap;
}

.hp-search-box {
    flex: 1;
    min-width: 250px;
    display: flex;
    gap: 0;
}

.hp-search-box input {
    flex: 1;
    height: 36px;
    padding: 0 0.75rem;
    border: 1px solid #d1d5db;
    border-right: none;
    border-radius: 4px 0 0 4px;
    font-size: 0.85rem;
    transition: border-color 0.2s;
}

.hp-search-box input:focus {
    outline: none;
    border-color: #003d82;
    box-shadow: 0 0 0 1px #003d82;
}

.hp-search-btn {
    height: 36px;
    padding: 0 1rem;
    background: #003d82;
    color: #fff;
    border: 1px solid #003d82;
    border-radius: 0 4px 4px 0;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    white-space: nowrap;
}

.hp-search-btn:hover {
    background: #002a5c;
}

.hp-filter-controls {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.hp-year-filter {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.hp-year-filter label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #4b5563;
}

.hp-year-filter select {
    height: 36px;
    padding: 0 2rem 0 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 0.85rem;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.2s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.6rem center;
    min-width: 110px;
}

.hp-year-filter select:focus {
    outline: none;
    border-color: #003d82;
}

.hp-clear-filters {
    height: 36px;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0 0.875rem;
    background: #fff;
    border: 1px solid #dc3545;
    color: #dc3545;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.hp-clear-filters:hover {
    background: #dc3545;
    color: #fff;
}

.hp-notices-count {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #6b7280;
}

/* ========== TABLE ========== */
.hp-notices-table-wrapper {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03);
    margin-bottom: 1rem;
}

.hp-notices-table {
    width: 100%;
    border-collapse: collapse;
}

.hp-notices-table thead {
    background: #1e3a5f;
}

.hp-notices-table thead th {
    color: #fff;
    font-weight: 600;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.7rem 0.75rem;
    text-align: left;
}

.hp-notices-table tbody tr {
    border-bottom: 1px solid #e5e7eb;
    transition: background 0.1s;
}

.hp-notices-table tbody tr:hover {
    background: #f9fafb;
}

.hp-notices-table tbody td {
    padding: 0.8rem 0.75rem;
    vertical-align: middle;
}

.hp-col-sno { width: 50px; }
.hp-col-date { width: 100px; text-align: center; }
.hp-col-action { width: 130px; text-align: center; }
.hp-td-sno { text-align: center; }
.hp-td-date { text-align: center; }
.hp-td-action { text-align: center; }

.hp-notice-sno {
    font-weight: 600;
    color: #6b7280;
    font-size: 0.8rem;
}

.hp-notice-date-cell {
    color: #4b5563;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
}

.hp-notice-info {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.hp-notice-table-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.3;
    margin: 0;
}

.hp-notice-table-description {
    font-size: 0.8rem;
    color: #4b5563;
    line-height: 1.4;
    margin: 0;
}

.hp-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    padding: 0.45rem 1rem;
    background: #003d82;
    color: #fff;
    text-decoration: none;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.2s;
    cursor: pointer;
}

.hp-download-btn:hover {
    background: #002a5c;
}

.hp-no-document {
    color: #9ca3af;
    font-size: 0.8rem;
}

.hp-highlighted-notice {
    background: #fffbeb !important;
    border-left: 3px solid #f59e0b;
}

.hp-flash-highlight {
    animation: flashHighlight 1.5s ease;
}

@keyframes flashHighlight {
    0%, 100% { background: #fffbeb; }
    50% { background: #fef3c7; }
}

.hp-no-results {
    text-align: center;
    padding: 2rem 1.5rem !important;
}

.hp-no-results-content h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #4b5563;
    margin: 0 0 0.3rem 0;
}

.hp-no-results-content p {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 0;
}

/* ========== PAGINATION ========== */
.hp-notices-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0;
    flex-wrap: wrap;
}

.hp-page-btn {
    background: #fff;
    color: #003d82;
    border: 2px solid #003d82;
    padding: 0.4rem 0.9rem;
    border-radius: 3px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.hp-page-btn:hover {
    background: #003d82;
    color: #fff;
}

.hp-page-numbers {
    display: flex;
    gap: 0.3rem;
}

.hp-page-number {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    font-weight: 600;
    font-size: 0.8rem;
    text-decoration: none;
    transition: all 0.15s;
    border: 1px solid #e5e7eb;
}

.hp-page-number:not(.active) {
    color: #6b7280;
    background: #f9fafb;
}

.hp-page-number:not(.active):hover {
    background: #e5e7eb;
    color: #003d82;
}

.hp-page-number.active {
    background: #003d82;
    color: #fff;
    border-color: #003d82;
}

.hp-page-dots {
    display: flex;
    align-items: center;
    padding: 0 0.3rem;
    color: #d1d5db;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    .hp-notices-archive {
        padding: 1rem 0.5rem;
    }
    
    .hp-archive-title {
        font-size: 1.3rem;
    }
    
    .hp-archive-controls {
        flex-direction: column;
    }
    
    .hp-search-box {
        min-width: 100%;
    }
    
    .hp-filter-controls {
        width: 100%;
    }
    
    .hp-year-filter select {
        width: 100%;
    }
    
    .hp-notices-table-wrapper {
        overflow: visible;
        border: none;
        background: transparent;
    }
    
    .hp-notices-table thead {
        display: none;
    }
    
    .hp-notices-table tbody {
        display: block;
    }
    
    .hp-notices-table tbody tr {
        display: block;
        margin-bottom: 0.75rem;
        border: 1px solid #e5e7eb;
        border-radius: 4px;
        padding: 0.75rem;
        background: #fff;
    }
    
    .hp-notices-table tbody td {
        display: block;
        padding: 0.3rem 0;
        border: none;
        text-align: left !important;
    }
    
    .hp-notice-sno,
    .hp-notice-date-cell {
        display: inline-block;
        background: #f3f4f6;
        padding: 0.2rem 0.5rem;
        border-radius: 3px;
        font-size: 0.7rem;
    }
    
    .hp-notice-date-cell {
        margin-left: 0.4rem;
    }
    
    .hp-td-info {
        margin: 0.5rem 0;
    }
    
    .hp-td-action {
        margin-top: 0.75rem;
    }
    
    .hp-download-btn {
        width: 100%;
    }
    
    .hp-ticker-view-all span:first-child {
        display: none;
    }
}

@media print {
    .hp-ticker-view-all,
    .hp-notices-pagination,
    .hp-new-badge,
    .hp-archive-controls-wrapper,
    .hp-download-btn {
        display: none;
    }
}