﻿@font-face {
    font-family: 'Inter';
    src: url('/fonts/Inter-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Inter';
    src: url('/fonts/Inter-Medium.woff2') format('woff2');
    font-weight: 500;
    font-style: normal;
}

/* ========== TABLE LOADING CONTAINER ========== */
.table-loading-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    padding: 40px;
}

/* ========== FARMS PAGE REDESIGN ========== */

.farms-page {
    font-family: 'Inter', sans-serif;
    max-width: calc(100% - 48px);
    margin-right: 24px;
    padding-bottom: 32px;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 0;
}

.breadcrumb-home-icon {
    width: 16px;
    height: 16px;
}

.breadcrumb-text {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #6B7280;
}

.breadcrumb-arrow {
    width: 16px;
    height: 16px;
}

.breadcrumb-current {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #111827;
}

/* Page Header - matching Crews */
.farms-page-header {
    margin-bottom: 16px;
    display: block;
}

.farms-page-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.farms-page-title {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 18px;
    line-height: 27px;
    color: #000000;
    margin: 0;
    outline: none;
}

.farms-page-title:focus {
    outline: none;
    box-shadow: none;
}

    .create-ranch-allocations-row select:focus {
        outline: none;
        box-shadow: none;
    }

.create-ranch-allocations-row input:focus {
    outline: none;
    box-shadow: none;
}


.farms-page-header .info-icon {
    width: 18px;
    height: 18px;
    opacity: 0.6;
    cursor: pointer;
}

.farms-page-description {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #6B7280;
    margin: 0;
}

/* Tab Strip Container - full width with card background */
.farms-tab-container {
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 8px;
    padding: 8px 12px;
    margin-bottom: 16px;
}

.farms-tab-strip {
    display: flex;
    align-items: center;
    gap: 4px;
    background: transparent;
    padding: 0;
    width: fit-content;
}

.farms-tab-item {
    padding: 8px 16px;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
}

.farms-tab-item:hover {
    background: rgba(8, 48, 80, 0.1);
}

.farms-tab-item.active {
    background: #083050;
    color: #FFFFFF;
}

/* Search Container - matching Crews */
.farms-search-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-top: 0.63px solid #E5E7EB80;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    margin-bottom: 16px;
    overflow: visible;
    position: relative;
    z-index: 10;
}

.farms-filter-section {
    display: flex;
    gap: 24px;
}

.farms-filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    position: relative;
    z-index: 100;
}

.no-results {
    padding: 40px;
    text-align: center;
    color: #6B7280;
    font-family: Inter, sans-serif;
    font-size: 14px;
    background: #FFFFFF;
    border: 0.63px solid #DADADA;
    border-radius: 10px;
    margin-top: 0;
}

.farms-filter-label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 20px;
    color: #374151;
}

.farms-search-input-wrapper {
    position: relative;
    width: 296px;
}

.farms-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    pointer-events: none;
    opacity: 0.5;
}

.farms-search-input {
    width: 100%;
    height: 40px;
    padding: 8px 12px 8px 36px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    border: 0.63px solid #D1D5DB;
    border-radius: 8px;
    background-color: #F9FAFB;
    box-sizing: border-box;
}

.farms-search-input::placeholder {
    color: #9CA3AF;
}

.farms-search-input:focus {
    outline: none;
    border-color: #D1D5DB;
    box-shadow: none;
}

/* Global focus styles - remove outline from all interactive elements */
.farms-page input:focus,
.farms-page select:focus,
.farms-page button:focus,
.farms-page textarea:focus {
    outline: none;
    box-shadow: none;
}

.farms-filter-dropdown-new:focus {
    outline: none;
    box-shadow: none;
}

.activity-multi-select-btn:focus,
.farms-column-toggle-btn:focus {
    outline: none;
    box-shadow: none;
}

.farms-action-section {
    display: flex;
    align-items: center;
}

/* Status dropdown - matching Crews */
.farms-filter-dropdown {
    width: 220px;
    max-width: 100%;
    height: 40px;
    padding: 8px 12px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    border: 0.63px solid #D1D5DB;
    border-radius: 8px;
    background-color: #F9FAFB;
    appearance: none;
    background-image: url('/images/chevron-down.svg');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    cursor: pointer;
}

.farms-filter-dropdown:focus {
    outline: none;
    border-color: #D1D5DB;
}

.farms-create-button {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 10px 16px;
    background: #083050;
    border: none;
    border-radius: 8px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #FFFFFF;
    cursor: pointer;
    transition: background 0.2s ease;
}

.farms-create-button:hover {
    background: #0a3d66;
}

.farms-create-button .plus-icon {
    font-size: 16px;
    font-weight: 600;
}

/* Table */
.farms-table {
    background: #FFFFFF;
    border: 0.63px solid #DADADA;
    border-radius: 10px;
    box-shadow: 0px 1px 2px -1px rgba(0, 0, 0, 0.1), 0px 1px 3px 0px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.farms-table .table-header {
    display: flex;
    background: #FFFFFF;
    border-bottom: 1px solid #E5E7EB;
    padding: 0;
}

.farms-table .table-header .header-cell {
    flex: 1;
    padding: 14px 16px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.farms-table .table-row {
    display: flex;
    border-bottom: 1px solid #E5E7EB;
    transition: background 0.2s ease;
    min-height: 48px;
}

.farms-table .table-row:hover {
    background: #F9FAFB;
}

.farms-table .table-row:last-child {
    border-bottom: none;
}

.farms-table .table-cell {
    flex: 1;
    padding: 12px 16px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
    display: flex;
    align-items: center;
}

/* Status badges - matching Crews */
.farms-status-active {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 53.41px;
    height: 21.23px;
    padding: 0 8px;
    background-color: #DCFCE7;
    color: #166534;
    border-radius: 6px;
    border: 0.63px solid #A7F3D0;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
}

.farms-status-inactive {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 53.41px;
    height: 21.23px;
    padding: 0 8px;
    background-color: #F3F4F6;
    color: #6B7280;
    border-radius: 6px;
    border: 0.63px solid #E5E7EB;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
}

/* Action buttons */
.farms-table .disable-button,
.farms-table .activate-button {
    padding: 6px 16px;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid;
    transition: all 0.2s ease;
}

.farms-table .disable-button {
    background: #ECFDF5;
    border-color: #059669;
    color: #059669;
}

.farms-table .disable-button:hover {
    background: #D1FAE5;
}

.farms-table .activate-button {
    background: #FEF2F2;
    border-color: #DC2626;
    color: #DC2626;
}

.farms-table .activate-button:hover {
    background: #FEE2E2;
}

/* Action status buttons - matching Crews */
.farms-action-enabled {
    min-width: 86px;
    height: 28px;
    border-radius: 6px;
    border: 0.63px solid #A7F3D0;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
    background-color: #DCFCE7;
    color: #166534;
}

.farms-action-enabled:hover {
    background-color: #BBF7D0;
}

.farms-action-disabled {
    min-width: 86px;
    height: 28px;
    border-radius: 6px;
    border: 0.63px solid #E5E7EB;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
    background-color: #F3F4F6;
    color: #6B7280;
}

.farms-action-disabled:hover {
    background-color: #E5E7EB;
}

/* Legacy wrapper - keep for compatibility */
.farms-page-wrapper {
    margin-top: 25px;
}

body, html {
    font-family: 'Inter', sans-serif;
}

/* Legacy styles removed - using farms-page-header from top of file */

.search-section {
    display: flex;
    justify-content: space-between; /* NEW: pushes content to edges */
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap; /* allows wrapping on smaller screens */
}
.search-left-group {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}


.search-input {
    width: 511px;
    padding: 10px 14px 10px 40px;
    font-size: 16px;
    border: 1px solid #CCCCCC;
    border-radius: 6px;
    height: 41px;
}

    .search-input::placeholder {
        color: #CCCCCC;
    }


.search-filters {
    display: flex;
    gap: 16px;
    font-size: 14px;
    color: #333;
    white-space: nowrap;
    flex-shrink: 0;
}

.search-input-wrapper {
    position: relative;
    width: 511px;
}

.search-icon {
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    pointer-events: none;
}
.search-input-container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 6px;
    border: 1px solid #ccc;
    border-radius: 6px;
    min-height: 40px;
    background-color: #fff;
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 400;
}

    .filter-option input[type="radio"] {
        accent-color: #083050;
        height: 16px;
        width: 18px;
    }

.user-table {
    width: 95%;
    border: 1px solid #DADADA;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 5px 15px 25px 0px #DCDCE5;
    background-color: #fff;
    /*overflow-x: auto;*/
}


.table-header {
    display: flex;
    font-weight: 500;
    font-size: 18px;
    padding: 12px;
    border-bottom: 3px solid #E0E0E0;
    text-align: center;
    justify-content: center;
    background-color: white;
}

    .table-header .table-cell {
        font-size: 18px;
        font-weight: 500;
        color: #333;
    }

.table-row .table-cell .practices-table-row {
    font-size: 14px;
    font-weight: 400;
    color: #000000;
}

.header-cell {
    justify-content: flex-start !important; /* center header content only */
    min-width: 120px; /* or more depending on your layout */
    flex: 0 0 auto;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
}

    .header-cell.username-cell {
        min-width: 160px;
    }

    .header-cell.company-cell {
        min-width: 160px;
    }

.table-wrapper {
    overflow-x: auto;
    width: 100%;
}


.table-row {
    display: flex;
    align-items: center;
    /*padding: 13px 20px; *//* increased padding */
    border-bottom: 1px solid #e0e0e0;
    cursor: pointer;
    flex-wrap: nowrap;
    transition: background-color 0.2s ease;
    min-height: 40px; /* optional: ensures consistent row height */
}

/* Practice tab specific styles */
.farms-table .practices-table-header {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr 0.8fr 0.8fr;
    background: #FFFFFF;
    border-bottom: 1px solid #E5E7EB;
    padding: 0;
}

.practices-table-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr 0.8fr 0.8fr;
    align-items: center;
    
    border-bottom: 1px solid #e0e0e0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    min-height: 48px;
}

.practices-table-row:hover {
    background-color: #F9FAFB;
}


    .table-row:hover {
        background-color: #F9FAFB;
    }

.search-input:focus {
    outline: none;
    border: 1px solid #ccc; /* or any subtle color you prefer */
    box-shadow: none; /* removes any glow effect */
}


.table-cell {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    color: #333;
    min-width: 100px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    height: auto; /* let content define height */
    line-height: 1.5;
}

.name-cell {
    justify-content: flex-start;
    padding-left: 25px;
}

.sort-icon {
    width: 18px;
    height: 18px;
    cursor: pointer;
}


.table-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    font-size: 14px;
    font-weight: 400;
    color: #666;
    border-top: 0px solid;
    width: 96%; /* match .user-table */
    box-sizing: border-box;
}

.footer-right {
    display: flex;
    justify-content: flex-end;
    flex-grow: 1;
}

.scroll-top-button {
    background-color: #083050;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
}

.scroll-top-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}

.scroll-top-icon {
    width: 40px;
    height: 40px;
}

.scroll-top-label {
    margin-top: 6px;
    font-size: 14px;
    color: #333;
}

.new-config-button {
    background-color: #F2F2F7;
    color: #000000;
    padding: 6px 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    white-space: nowrap;
    font-size: 18px;
    font-weight: 400;
    margin-right: 5px;
    height: 41px;
    transition: background-color 0.2s ease;
}

    .new-config-button:hover {
        background-color: #083050;
        color: #ffffff;
    }

.no-association {
    background-color: #FFCD71;
    color: #68480D;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 400;
    width: 110px;
}

.view-button {
    background-color: #DCFCE7;
    color: #166534;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    width: 96px;
}

.row-light {
    background-color: #F9FAFB;
}

.row-white {
    background-color: #FFFFFF;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

/* Modal Box */
.modal-box {
    background-color: #fff;
    border-radius: 20px; /* updated from 12px */
    width: 1166px; /* updated from 800px */
    height: 701px; /* added height from Figma */
    padding: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    position: relative;
    color: #000;
    display: flex;
    flex-direction: column;
    opacity: 1; /* explicitly set */
}


.modal-content {
    padding: 43px;
    overflow-y: auto;
    flex-grow: 1;
}

/* Modal Header */
.modalheader {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: -15px;
}

.modalconfigheader {
    font-size: 22px;
    font-weight: 500;
    color: #000000;
    margin-left: -26px;
}

.arrowicon {
    margin-left: -2px;
    height: 16px;
    cursor: pointer;
}

.back {
    font-size: 14px;
    font-weight: 400;
    color: #000000;
    margin-left: 9px;
    cursor: pointer;
}

.modal-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.modal-ranch-section {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.modal-divider {
    height: 1px;
    background-color: #DBDBDB;
    margin: 16px -43px;
}

.modal-row {
    display: flex;
    justify-content: space-between;
    gap: 32px;
    padding-top: 6px;
}

.modal-label-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .modal-label-group label {
        font-size: 18px;
        font-weight: 500;
        color: #000;
    }

    .modal-label-group p {
        font-size: 14px;
        font-weight: 300;
        color: #666;
    }

/* Value Display */
.modal-value {
    background-color: #F8FAFC;
    padding: 8px 12px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    font-weight: 400;
    color: #636363;
    border: 1px solid #DBDBDB;
    height: 51px;
}

.closeicon.clickable {
    width: 16px;
    height: 16px;
    cursor: pointer;
    /*    margin-left: 283px;
    margin-top: -39px;*/
}

.modal-value-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #F8FAFC;
    padding: 8px 12px;
    border: 1px solid #DBDBDB;
    width: 353px;
    height: 50px;
    opacity: 1;
    border-radius: 10px;
    border-width: 1px;
}

.modal-input {
    width: 100%;
    font-size: 14px;
    font-weight: 400;
    color: #636363;
    background-color: #F8FAFC;
    border: none;
    border-radius: 6px;
    padding: 8px 12px;
    outline: none;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    margin-top: 92px;
    height: 50px;
    margin-right: 63px;
}

.reset-button,
.save-button {
    padding: 8px 16px;
    border-radius: 8px;
    border: none;
    font-size: 18px;
    font-weight: 400;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    line-height: 1.4;
    border: 1px solid #083050;
    height: 45px;
}

.reset-button {
    background-color: white;
    color: #000000;
}

.save-button {
    background-color: #083050;
    color: #fff;
}

.closeicon {
    height: 16px;
    cursor: pointer;
}

.save-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
/* Chrome, Safari, Edge */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

.profile-summary-box {
    background-color: #F8FAFC;
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 24px;
    border: 1px solid #DBDBDB;
}

.profile-summary-content {
    display: flex;
    align-items: center;
    gap: 16px;
}

.save-message {
    margin-top: 10px;
    font-weight: bold;
    color: green;
}


.profile-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    background-color: #ccc;
}

.profile-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}

.profile-name-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-name {
    font-size: 20px;
    font-weight: 400;
    color: #636363;
}

.status-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: #DCFCE7;
    padding: 6px 11px;
    border-radius: 12px;
}

.practice-status-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: #F39D6A;
    padding: 6px 11px;
    border-radius: 12px;
}

.status-icon {
    width: 16px;
    height: 16px;
}

.status-text {
    font-size: 14px;
    color: #166534;
    font-weight: 500;
}

.label-with-action {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.inline-inactive-button {
    font-size: 12px;
    font-weight: 400;
    color: #083050;
    background-color: transparent;
    border: 1px solid #DBDBDB;
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    border-radius: 13px;
    height: 29px;
    margin-top: -4px;
}

.employee-details-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    margin-top: 16px;
}

.header-title {
    font-size: 22px;
    font-weight: 500;
    color: #000000;
}

/* Tabs */
.tab-strip {
    display: flex;
    gap: 3rem;
    margin-bottom: 2rem;
}

.tab-item {
    font-size: 20px;
    font-weight: 600;
    color: #6B7280;
    padding-bottom: 6px;
    cursor: pointer;
    position: relative;
    text-align: center;
    width: 141px; /* fixed width ensures consistent alignment */
    display: flex;
    align-items: center;
    justify-content: center;
}

    .tab-item.active-tab {
        color: #083050;
        border-bottom: 4px solid #083050;
    }


/* Category Pills */
/* Base Pill Style */
.pill {
    width: 130px; /* rounded from 129.9453125 */
    height: 24px;
    border-radius: 10px;
    opacity: 1;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    box-sizing: border-box;
}

/* Category Pills */
.pill-general {
    background-color: #A1F9A1;
    color: black;
}

.pill-test {
    background-color: #DBE9FE;
    color: black;
}

/* Status Pill */
.status-pill {
    background-color: #DBE9FE;
    color: black;
}

/* Action Button (Disable) */
.disable-button {
    background-color: #DCFCE7;
    color: #166534;
    border: none;
    padding: 2px 12px;
    border-radius: 7px;
    cursor: pointer;
}

.radio-group {
    display: flex;
    gap: 2rem;
    margin-top: 8px;
}

    .radio-group label {
        font-size: 16px;
        font-weight: 500;
        cursor: pointer;
    }

.newbutton {
    margin-left: auto;
    margin-right: 4.5%; /* aligns with .user-table's right edge */
}
.activate-button {
    background-color: #DCFCE7;
    color: #166534;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
}

.pill-highlight {
    background-color: #DBE9FE;
    color: #000000;
    padding: 4px 40px;
    border-radius: 12px;
    font-size: 0.875rem;
}
.pill-active {
    background-color: #D1FAE5;
    color: #065F46;
    padding: 4px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.pill-inactive {
    background-color: #FEE2E2;
    color: #991B1B;
    padding: 4px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #22C55E;
    border-radius: 50%;
    margin-right: 8px;
    vertical-align: middle;
}

/* Legacy status styles removed - using farms-status-active/inactive from top of file */

.practice-table {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr; /* 5 equal columns */
    gap: 8px;
}

.practice-table-header,
.practice-table-row {
    display: contents; /* let children participate in the parent grid */
}

    .practice-table-header div,
    .practice-table-row div {
        padding: 6px;
        border-bottom: 1px solid #ccc;
    }



.status-dot-active {
    background-color: #22C55E;
}

.status-dot-inactive {
    background-color: #6B7280;
}

.view-button {
    background-color: #D1FAE5;
    color: #065F46;
    border: none;
    padding: 4px 12px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
}

input[type="checkbox"] {
    accent-color: white;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.allocation-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 20px 40px;
}

.allocation-left,
.allocation-right {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-field label {
    font-weight: 600;
    margin-bottom: 6px;
    color: #374151;
}

.input-box {
    padding: 8px 12px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-size: 14px;
    background-color: #F9FAFB;
    width: 100%;
}

.planting-suggestions {
    list-style: none;
    padding: 0;
    margin-top: 8px;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    background-color: #FFFFFF;
    max-height: 150px;
    overflow-y: auto;
}

    .planting-suggestions li {
        padding: 8px 12px;
        cursor: pointer;
        border-bottom: 1px solid #F3F4F6;
    }

.selected-tags {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/*.tag {
    background-color: #E0F2FE;
    color: #0369A1;
    padding: 8px 45px;
    border-radius: 23px;
    font-size: 12px;
    display: flex;
    align-items: center;
}*/
.tag {
    font-size: 12px;
    font-weight: 300;
    padding: 8px 45px;
    border-radius: 23px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

    .tag button {
        background: none;
        border: none;
        margin-left: 6px;
        font-size: 16px;
        cursor: pointer;
        color: #0369A1;
    }

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

.allocation-table th,
.allocation-table td {
    padding: 10px;
    border: 1px solid #E5E7EB;
    text-align: left;
    font-size: 14px;
}

.gauge-chart {
    margin-top: 20px;
    text-align: center;
}

.chart-title {
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
    font-size: 16px;
}

.empty-state {
    color: #6B7280;
    font-size: 14px;
    margin-top: 20px;
}

.search-wrapper {
    position: relative;
    width: 86%;
}


.modal-search {
    position: relative;
}

    .modal-search .icon {
        position: absolute;
        right: 12px;
        top: 50%;
        transform: translateY(-50%);
    }
.modal-tags {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag.color-1 {
    background-color: #71B7B6;
    color: #FFFFFF;
}

.tag.color-2 {
    background-color: #A1EAE9;
    color: #083050;
}

    .tag.color-3 {
        background-color: #E0F2FE; /* light blue */
        color: #0369A1;
    }

    .tag.color-4 {
        background-color: #FEF9C3; /* pale yellow */
        color: #92400E;
    }
.modal-grid {
    display: flex;
    gap: 16px;
}

.modal-left {
    flex: 1;
    min-width: 300px;
}

.modal-right {
    flex: 1.6;
    min-width: 500px;
}

.modal-preview-box {
    border: 1px solid #DADADA;
    border-radius: 8px;
    /*    padding: 16px;*/
    min-height: 300px;
}

.placeholder-text {
    color: #999;
    font-style: italic;
}


.remove-icon {
    margin-left: 4px;
    cursor: pointer;
    color: inherit;
    border-radius: 50%;
    padding: 0 6px;
}
    .modal-search input {
        width: 100%;
        padding: 8px 12px;
        border-radius: 8px;
        border: 1px solid #DBDBDB;
        background-color: #F8FAFC;
        height: 51px;
        color: #636363;
    }

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #ffffff;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    margin-top: 4px;
    padding: 0;
    list-style: none;
}

    .search-results li {
        padding: 10px 14px;
        cursor: pointer;
        font-size: 14px;
        border-bottom: 1px solid #F3F4F6;
    }

        .search-results li:hover {
            background-color: #F9FAFB;
        }
.practice-table-container {
    /*box-shadow: 0 5px 12px rgba(0, 0, 0, 0.15);*/ /* slightly deeper shadow */
    border-radius: 2px;
    background-color: #fff;
    /*padding: 16px 0px;*/
    width: 95%;
    margin-left: 51px;
    margin-bottom: 41px; /* ✅ adds space below the box */
    border: 1px solid #E5E7EB;
}

.practice-table-container {
    margin-left: 0;
    width: 100%;
    overflow-x: auto;
}

.practice-table-container {
    width: 100%;
    margin-left: 0;
}

.practice-table {
    display: flex;
    flex-direction: column;
    gap: 13px;
}

.practice-table-header,
.practice-table-row {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 1.5fr 1fr 1fr;
    align-items: center;
    padding: 8px 16px;
    width: 100%;
    box-sizing: border-box;
    gap: 23px;
}


    .practice-table-header div,
    .practice-table-row div {
        display: flex;
        justify-content: flex-start;
        align-items: center;
    }

.practice-table-header {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 1.5fr 1fr 1fr;
    align-items: center;
    background-color: white;
    color: #222222;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    border-bottom: 1px solid #E5E7EB;
    padding: 2px 16px;
    width: 100%;
    box-sizing: border-box;
}

.table-input {
    width: 100%;
    max-width: 180px; /* prevents overflow */
    padding: 4px 1px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    outline: none;
}


.date-range {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: nowrap;
    outline: none;
}

.save-feedback {
    margin-top: -7px;
    font-weight: bold;
    margin-left: 37%;
}

.success {
    color: green;
}

.error {
    color: red;
}
.ranch-save-message {
    text-align: center;
    font-weight: bold;
    margin-top: 12px;
    padding: 10px;
    border-radius: 6px;
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
}

    .ranch-save-message.success {
        color: #155724;
        margin-top: 24px;
    }

    .ranch-save-message.error {
        color: #721c24;
        margin-top: 24px;
    }

.task-save-message {
    text-align: center;
    font-weight: bold;
    margin-top: 12px;
    padding: 10px;
    border-radius: 6px;
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
}

    .task-save-message.success {
        color: #155724;
        margin-top:-91px;
    }

    .task-save-message.error {
        color: #721c24;
        margin-top: -91px;
    }
@media screen and (max-width: 1366px) {
    .search-section {
        gap: 12px;
    }

    .search-left-group {
        gap: 16px;
    }

    .search-input,
    .search-input-wrapper {
        width: 376px;
    }

    .new-config-button {
        font-size: 16px;
        padding: 6px 10px;
        height: 38px;
    }

    .table-header .table-cell,
    .table-row .practices-table-row {
        font-size: 16px;
    }

    .header-cell.username-cell,
    .header-cell.company-cell {
        min-width: 140px;
    }

    .table-cell {
        min-width: 90px;
        font-size: 13px;
    }

     ✅ Updated modal styles for consistency 
    .modal-box {
        width: 720px;
        max-width: 85vw;
        padding: 0;
    }

    .modal-content {
        padding: 28px;
        overflow: hidden;
    }

    .modalconfigheader {
        font-size: 20px;
        margin-left: -12px;
    }

    .modal-label-group label {
        font-size: 15px;
    }

    .modal-label-group p {
        font-size: 13px;
    }

    .modal-value,
    .modal-value-group,
    .modal-dropdown,
    .modal-search input {
        font-size: 13px;
        height: 44px;
        padding: 6px 10px;
    }

    .modal-actions {
        margin-top: 40px;
        gap: 12px;
    }

    .reset-button,
    .save-button {
        font-size: 13px;
        padding: 6px 12px;
    }

    .table-row {
        padding: 14px 16px;
        font-size: 14px;/* reduced from 15px 20px */
    }
    .table-header {
        padding: 10px 16px;
    }


    .tab-item {
        font-size: 18px;
        width: 120px;
    }

    .pill {
        font-size: 0.8rem;
        width: 120px;
    }

    .practice-table-header,
    .practice-table-row {
        gap: 18px;
        padding: 6px 12px;
    }

    .table-input {
        max-width: 160px;
        font-size: 13px;
    }

    .allocation-layout {
        gap: 24px;
        padding: 16px 24px;
    }

    .input-box {
        font-size: 13px;
    }

    .search-wrapper {
        width: 92%;
    }

    .scroll-top-button {
        padding: 5px 10px;
        font-size: 13px;
    }

    .scroll-top-icon {
        width: 36px;
        height: 36px;
    }

    .scroll-top-label {
        font-size: 13px;
    }
}

/*@media screen and (max-width: 1366px) {
    .search-section {
        gap: 12px;
    }

    .search-left-group {
        gap: 16px;
    }

    .search-input,
    .search-input-wrapper {
        width: 376px;
    }

    .new-config-button {
        font-size: 16px;
        padding: 6px 10px;
        height: 38px;
    }

    .table-header .table-cell,
    .table-row .table-cell {
        font-size: 16px;
    }

    .header-cell.username-cell,
    .header-cell.company-cell {
        min-width: 140px;
    }

    .table-cell {
        min-width: 90px;
        font-size: 13px;
    }

    .modal-box {
        width: 95vw;
        height: auto;
        max-height: 90vh;
    }

    .modal-content {
        padding: 32px;
    }

    .modal-label-group label {
        font-size: 16px;
    }

    .modal-value,
    .modal-value-group {
        height: 45px;
        font-size: 13px;
    }

    .reset-button,
    .save-button {
        font-size: 16px;
        height: 42px;
    }

    .tab-item {
        font-size: 18px;
        width: 120px;
    }

    .pill {
        font-size: 0.8rem;
        width: 120px;
    }

    .practice-table-header,
    .practice-table-row {
        gap: 18px;
        padding: 6px 12px;
    }

    .table-input {
        max-width: 160px;
        font-size: 13px;
    }

    .allocation-layout {
        gap: 24px;
        padding: 16px 24px;
    }

    .input-box {
        font-size: 13px;
    }

    .search-wrapper {
        width: 92%;
    }

    .scroll-top-button {
        padding: 5px 10px;
        font-size: 13px;
    }

    .scroll-top-icon {
        width: 36px;
        height: 36px;
    }

    .scroll-top-label {
        font-size: 13px;
    }
}*/

/* ==================== CREATE RANCH MODAL ==================== */
.create-ranch-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.45);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 16px;
}

.create-ranch-modal {
    position: relative;
    width: 894px;
    max-width: calc(100vw - 32px);
    max-height: calc(100vh - 32px);
    background: #FFFFFF;
    border-radius: 8px;
    border: 0.63px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    font-family: Inter, sans-serif;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.create-ranch-modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    font-size: 20px;
    color: #6B7280;
    line-height: 1;
}

.create-ranch-modal-close:hover {
    color: #111827;
}

.create-ranch-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 24px 24px 20px;
}

.create-ranch-icon {
    width: 35px;
    height: 35px;
    border-radius: 7px;
    background: linear-gradient(180deg, #083050 0%, #105583 100%);
    box-shadow: 0px 2px 4px -2px #0000001A, 0px 4px 6px -1px #0000001A;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.create-ranch-icon img {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
}

.create-ranch-title-block {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.create-ranch-title-block h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #111827;
    line-height: 28px;
}

.create-ranch-title-block p {
    margin: 0;
    font-size: 12.25px;
    font-weight: 400;
    color: #6B7280;
    line-height: 17.5px;
}

.create-ranch-body {
    padding: 16px 25px 0;
    display: flex;
    flex-direction: column;
    gap: 24px;
    overflow-y: auto;
    flex: 1;
}

.create-ranch-field-row {
    display: flex;
    gap: 16px;
}

.create-ranch-field-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.create-ranch-field-group.full {
    flex: 0 0 calc(50% - 8px);
}

.create-ranch-field-group label {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    line-height: 14px;
}

.create-ranch-input {
    width: 100%;
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px;
    font-size: 14px;
    font-weight: 400;
    color: #111827;
    font-family: Inter, sans-serif;
    box-sizing: border-box;
}

.create-ranch-input::placeholder {
    color: #6B7280;
}

    .create-ranch-input:focus {
        outline: none;
        border-color: none;
    }

.create-ranch-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236B7280' d='M2.5 4.5L6 8l3.5-3.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
    cursor: pointer;
    color: #9CA3AF;
}

.create-ranch-select.has-value {
    color: #111827;
}

.create-ranch-date-wrapper {
    position: relative;
}

.create-ranch-date-wrapper img {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    pointer-events: none;
}

.create-ranch-date-wrapper .create-ranch-input {
    padding-left: 36px;
}

/* Checkbox Section */
.create-ranch-checkbox-section {
    padding: 24px 0 0;
    border-top: 0.63px solid #E5E7EB;
}

.create-ranch-checkbox-row {
    display: flex;
    gap: 32px;
    flex-wrap: wrap;
}

.create-ranch-checkbox-item {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.create-ranch-checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    border-radius: 4px;
    border: 1px solid #D1D5DB;
    accent-color: #083050;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-color: #F9FAFB;
    position: relative;
}

.create-ranch-checkbox-item input[type="checkbox"]:checked {
    background-color: #083050;
    border-color: #083050;
}

.create-ranch-checkbox-item input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: bold;
}

.create-ranch-checkbox-item span {
    font-size: 14px;
    font-weight: 400;
    color: #374151;
    line-height: 14px;
}

/* Ranch Multi-Select Dropdown */
.ranch-multi-select-wrapper {
    position: relative;
    width: 100%;
}

.ranch-multi-select-btn {
    width: 100%;
    height: 40px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    background: #F9FAFB;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    cursor: pointer;
    text-align: left;
}

.ranch-multi-select-btn:hover {
    background: #F3F4F6;
}

.ranch-multi-select-dropdown {
    position: absolute;
    top: 44px;
    left: 0;
    width: 100%;
    max-height: 250px;
    overflow-y: auto;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 8px;
    box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 100;
    padding: 8px 0;
}

.ranch-multi-select-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    cursor: pointer;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
}

.ranch-multi-select-item:hover {
    background: #F9FAFB;
}

.ranch-multi-select-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    border-radius: 4px;
    border: 1px solid #083050;
    accent-color: #083050;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-color: #FFFFFF;
    position: relative;
}

.ranch-multi-select-item input[type="checkbox"]:checked {
    background-color: #083050;
    border-color: #083050;
}

.ranch-multi-select-item input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: bold;
}

.ranch-multi-select-footer {
    border-top: 0.63px solid #E5E7EB;
    padding: 12px 16px;
    margin-top: 8px;
    display: flex;
    justify-content: flex-end;
}

.ranch-multi-select-clear {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: transparent;
    border: none;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #6B7280;
    cursor: pointer;
}

.ranch-multi-select-clear:hover {
    color: #374151;
}

/* Associated Allocations Table */
.create-ranch-allocations {
    margin-top: 24px;
}

.create-ranch-allocations-title {
    font-size: 12.25px;
    font-weight: 500;
    color: #111827;
    line-height: 17.5px;
    margin-bottom: 12px;
}

.create-ranch-allocations-table {
    border: 2px solid #E5E7EB;
    border-radius: 11px;
    overflow: hidden;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
}

.create-ranch-allocations-header {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
    background: linear-gradient(180deg, #F9FAFB 0%, #F3F4F6 100%);
    border-bottom: 1px solid #E5E7EB;
    padding: 12px 16px;
}

.create-ranch-allocations-header span {
    font-size: 12.25px;
    font-weight: 600;
    color: #374151;
    line-height: 17.5px;
}

.create-ranch-allocations-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
    padding: 12px 16px;
    align-items: center;
}

.create-ranch-allocations-row select,
.create-ranch-allocations-row input {
    height: 31.5px;
    
    border: none;
    background: #F9FAFB;
    padding: 0 10.5px;
    font-size: 12.25px;
    font-weight: 400;
    color: #111827;
    font-family: Inter, sans-serif;
    box-sizing: border-box;
    width: 90%;
}

.create-ranch-allocations-row select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236B7280' d='M2.5 4.5L6 8l3.5-3.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 28px;
    cursor: pointer;
}

/* Modal Footer */
.create-ranch-footer {
    display: flex;
    justify-content: center;
    gap: 7px;
    padding: 24px;
    /*border-top: 0.63px solid #E5E7EB;*/
    margin-top: auto;
}

.create-ranch-clear-btn {
    height: 32px;
    min-width: 100px;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    background: #FFFFFF;
    font-size: 12.25px;
    font-weight: 500;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: Inter, sans-serif;
    line-height: 17.5px;
}

.create-ranch-clear-btn:hover {
    background: #F9FAFB;
}

.create-ranch-save-btn {
    height: 32px;
    min-width: 110px;
    border-radius: 8px;
    border: none;
    background: #083050;
    font-size: 12.25px;
    font-weight: 500;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: Inter, sans-serif;
    line-height: 17.5px;
}

.create-ranch-save-btn:hover {
    background: #1570EF;
}

.create-ranch-save-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.create-ranch-save-btn img {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

/* Alert Messages */
.create-ranch-alert {
    width: 100%;
    margin: 16px 0 0 0;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    border-radius: 6px;
    padding: 10px 14px;
    text-align: center;
    box-sizing: border-box;
}

.create-ranch-alert.alert-success {
    background: #ECFDF5;
    color: #065F46;
    border: 1px solid #A7F3D0;
}

.create-ranch-alert.alert-danger {
    background: #FEF2F2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

/* ============================================
   VIEW ALLOCATIONS MODAL STYLES
   ============================================ */

.view-allocations-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.view-allocations-modal {
    width: 920px;
    height: 806px;
    background: #FFFFFF;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.view-allocations-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 10;
}

.view-allocations-modal-close:hover {
    color: #374151;
}

.view-allocations-modal-close:focus {
    outline: none;
    box-shadow: none;
}

/* Header */
.view-allocations-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 24px 24px 20px 24px;
}

.view-allocations-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    border-radius: 7px;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    box-shadow: 0px 0.88px 1.75px -0.44px #0000001A, 0px 1.75px 5.25px 0px #00000026;
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-allocations-icon img {
    width: 18px;
    height: 18px;
    filter: brightness(0) invert(1);
}

.view-allocations-title-block h2 {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 20px;
    line-height: 28px;
    color: #111827;
    margin: 0 0 2px 0;
}

.view-allocations-title-block p {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #6B7280;
    margin: 0;
}

/* Body */
.view-allocations-body {
    flex: 1;
    padding: 0 24px 24px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.view-allocations-field-row {
    display: flex;
    gap: 24px;
}

.view-allocations-field-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.view-allocations-field-group.full {
    flex: 0 0 calc(50% - 12px);
}

.view-allocations-field-group label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.view-allocations-input {
    height: 40px;
    border-radius: 8px;
    border: 1px solid #D1D5DB;
    background: #F9FAFB;
    padding: 0 14px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    width: 100%;
    box-sizing: border-box;
}

.view-allocations-input:focus {
    outline: none;
    box-shadow: none;
}

.view-allocations-input::placeholder {
    color: #9CA3AF;
}

.view-allocations-input[readonly] {
    background: #F3F4F6;
    cursor: default;
}

.view-allocations-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.view-allocations-select:disabled {
    background-color: #F3F4F6;
    cursor: default;
    opacity: 1;
}

.view-allocations-select {
    color: #9CA3AF;
}

.view-allocations-select.has-value {
    color: #111827;
}

/* Checkbox Section */
.view-allocations-checkbox-section {
    padding: 24px 0 0;
    border-top: 0.63px solid #E5E7EB;
}

.view-allocations-checkbox-row {
    display: flex;
    gap: 32px;
    flex-wrap: wrap;
}

.view-allocations-checkbox-item {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.view-allocations-checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    border-radius: 4px;
    border: 1.5px solid #D1D5DB;
    background: #FFFFFF;
    appearance: none;
    cursor: pointer;
    position: relative;
}

.view-allocations-checkbox-item input[type="checkbox"]:checked {
    background-color: #083050;
    border-color: #083050;
}

.view-allocations-checkbox-item input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.view-allocations-checkbox-item input[type="checkbox"]:disabled {
    cursor: default;
    opacity: 0.6;
}

.view-allocations-checkbox-item span {
    font-size: 14px;
    font-weight: 400;
    color: #374151;
    line-height: 14px;
}

/* Alert Messages */
.view-allocations-alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 16px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
}

.view-allocations-alert.alert-success {
    background-color: #D1FAE5;
    color: #065F46;
    border: 1px solid #A7F3D0;
}

.view-allocations-alert.alert-danger {
    background-color: #FEE2E2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

.view-allocations-date-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.view-allocations-date-wrapper img {
    position: absolute;
    left: 14px;
    width: 16px;
    height: 16px;
    pointer-events: none;
}

.view-allocations-date-wrapper input {
    padding-left: 40px;
}

/* Associated Allocations Table Section */
.view-allocations-table-section {
    margin-top: 8px;
}

.view-allocations-table-title {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    margin-bottom: 12px;
}

.view-allocations-table-box {
    width: 846px;
    max-height: 268.5px;
    border-radius: 11px;
    border: 2px solid #E5E7EB;
    background: transparent;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    overflow: hidden;
}

.view-allocations-table-header {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    height: 42px;
    background: linear-gradient(180deg, #F9FAFB 0%, #F3F4F6 100%);
    border-bottom: 1px solid #E5E7EB;
    align-items: center;
    padding: 0 16px;
    box-sizing: border-box;
}

.view-allocations-table-header span {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
}

.view-allocations-table-row {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    min-height: 45px;
    padding: 10px 16px;
    box-sizing: border-box;
    align-items: center;
    border-bottom: 1px solid #F3F4F6;
}

.view-allocations-table-row:last-child {
    border-bottom: none;
}

.view-allocations-table-row span {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
/*    color: #374151;*/
    text-align: center;
}

.view-allocations-table-row span:first-child {
    text-align: left;
}

.planting-code-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

.planting-code-link {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #155DFC;
    text-decoration: none;
}

.planting-code-link:hover {
    text-decoration: underline;
}

.expired-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #EC003F;
    border: none;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 10px;
    line-height: 14px;
    color: #FFFFFF !important;
}

.expired-badge img {
    width: 12px;
    height: 12px;
}

/* Edit mode inputs in table */
.allocation-edit-input {
    height: 31.5px;
    border: none;
    background: #F9FAFB;
    padding: 0 10.5px;
    font-family: Inter, sans-serif;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
    width: 90%;
    box-sizing: border-box;
}

.allocation-edit-input:focus {
    outline: none;
    box-shadow: none;
}

.allocation-edit-select {
    height: 31.5px;
    border: none;
    background: #F9FAFB;
    padding: 0 10.5px;
    font-family: Inter, sans-serif;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
    width: 90%;
    box-sizing: border-box;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    padding-right: 24px;
}

.allocation-edit-select:focus {
    outline: none;
    box-shadow: none;
}

/* Footer */
.view-allocations-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 20px 0 12px;
    border-top: 1px solid #E5E7EB;
    margin-top: auto;
}

.view-allocations-clear-btn {
    width: 77px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-allocations-clear-btn:hover {
    background: #F9FAFB;
}

.view-allocations-clear-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-allocations-edit-btn {
    width: 68px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #8EC5FF;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #1447E6;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-allocations-edit-btn:hover {
    background: #F0F7FF;
}

.view-allocations-edit-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-allocations-edit-btn img {
    width: 14px;
    height: 14px;
}

.view-allocations-cancel-btn {
    width: 90px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-allocations-cancel-btn:hover {
    background: #F9FAFB;
}

.view-allocations-cancel-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-allocations-save-btn {
    height: 35px;
    padding: 0 16px;
    border-radius: 7px;
    border: none;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.view-allocations-save-btn:hover {
    background: #1570EF;
}

.view-allocations-save-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-allocations-save-btn img {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

/* Clickable row styling */
.clickable-row {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.clickable-row:hover {
    background-color: #F9FAFB;
}

/* ============================================
   CREATE PRACTICE MODAL STYLES
   ============================================ */

.create-practice-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999 !important;
}

.create-practice-modal {
    width: 920px;
    height: 493px;
    max-height: 90vh;
    background: #FFFFFF;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.create-practice-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 10;
}

.create-practice-modal-close:hover {
    color: #374151;
}

.create-practice-modal-close:focus {
    outline: none;
    box-shadow: none;
}

.create-practice-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 24px 24px 20px 24px;
}

.create-practice-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    border-radius: 7px;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    box-shadow: 0px 0.88px 1.75px -0.44px #0000001A, 0px 1.75px 5.25px 0px #00000026;
    display: flex;
    align-items: center;
    justify-content: center;
}

.create-practice-icon img {
    width: 18px;
    height: 18px;
    filter: brightness(0) invert(1);
}

.create-practice-title-block h2 {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 20px;
    line-height: 28px;
    color: #111827;
    margin: 0 0 2px 0;
}

.create-practice-title-block p {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #6B7280;
    margin: 0;
}

.create-practice-body {
    flex: 1;
    padding: 0 24px 24px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.create-practice-field-row {
    display: flex;
    gap: 24px;
    width: 100%;
}

.create-practice-field-row.two-column .create-practice-field-group {
    flex: 0 0 calc((100% - 24px) / 2);
}

.create-practice-field-row.two-column {
    justify-content: space-between;
    max-width: 750px;
}

.create-practice-field-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.create-practice-field-group.full-width {
    flex: 0 0 100%;
}

.create-practice-field-group label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.create-practice-input {
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    width: 100%;
    box-sizing: border-box;
}

.associated-ranches-row {
    justify-content: flex-start;
}

.associated-ranches-group {
    max-width: 750px;
    width: 100%;
}

.associated-ranches-input {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 36px;
    background: #F9FAFB;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    padding: 0 12px;
    box-sizing: border-box;
}

.associated-ranch-input {
    border: none;
    background: transparent;
    padding: 0;
    height: 100%;
}

.associated-ranch-input:disabled {
    color: #374151;
    opacity: 1;
}

.create-practice-input:focus {
    outline: none;
    box-shadow: none;
}

.create-practice-input::placeholder {
    color: #9CA3AF;
}

.create-practice-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.create-practice-area-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.create-practice-area-wrapper .create-practice-input {
    padding-right: 40px;
}

.create-practice-area-wrapper .area-unit {
    position: absolute;
    right: 14px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #6B7280;
}

.create-practice-table-section {
    margin-top: 8px;
}

.create-practice-table-title {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    margin-bottom: 12px;
}

.create-practice-table-box {
    width: 100%;
    max-height: 268.5px;
    border-radius: 11px;
    border: 2px solid #E5E7EB;
    background: transparent;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    overflow: hidden;
}

.create-practice-table-header {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    height: 42px;
    background: linear-gradient(180deg, #F9FAFB 0%, #F3F4F6 100%);
    border-bottom: 1px solid #E5E7EB;
    align-items: center;
    padding: 0 16px;
    box-sizing: border-box;
}

.create-practice-table-header span {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
}

.create-practice-table-row {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    min-height: 45px;
    padding: 10px 16px;
    box-sizing: border-box;
    align-items: center;
    border-bottom: 1px solid #F3F4F6;
}

.create-practice-table-row:last-child {
    border-bottom: none;
}

.create-practice-table-row span {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
    text-align: center;
}

.create-practice-table-row span:first-child {
    text-align: left;
}


.create-practice-footer {
    display: flex !important;
    justify-content: center !important;
    gap: 7px !important;
    padding: 24px !important;
    margin-top: auto !important;
}

.create-practice-clear-btn {
    all: unset !important;
    box-sizing: border-box !important;
    height: 32px !important;
    min-width: 100px !important;
    padding: 0 16px !important;
    border-radius: 8px !important;
    border: 1px solid #E5E7EB !important;
    background: #FFFFFF !important;
    font-size: 12.25px !important;
    font-weight: 500 !important;
    color: #111827 !important;
    cursor: pointer !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    font-family: Inter, sans-serif !important;
    line-height: 17.5px !important;
}

.create-practice-clear-btn:hover {
    background: #F9FAFB !important;
}

.create-practice-clear-btn:disabled {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
}

.create-practice-save-btn {
    all: unset !important;
    box-sizing: border-box !important;
    height: 32px !important;
    min-width: 110px !important;
    padding: 0 16px !important;
    border-radius: 8px !important;
    border: none !important;
    background: #083050 !important;
    font-size: 12.25px !important;
    font-weight: 500 !important;
    color: #FFFFFF !important;
    cursor: pointer !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    font-family: Inter, sans-serif !important;
    line-height: 17.5px !important;
}

.create-practice-save-btn:hover {
    background: #1570EF !important;
}

.create-practice-save-btn:disabled {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
}

.create-practice-save-btn img {
    width: 14px !important;
    height: 14px !important;
    filter: brightness(0) invert(1) !important;
}

.create-practice-alert {
    width: 100%;
    margin: 16px 0 0 0;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    border-radius: 6px;
    padding: 10px 14px;
    text-align: center;
    box-sizing: border-box;
}

.create-practice-alert.alert-success {
    background: #ECFDF5;
    color: #065F46;
    border: 1px solid #A7F3D0;
}

.create-practice-alert.alert-danger {
    background: #FEF2F2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

.create-practice-empty-state {
    padding: 24px;
    text-align: center;
    color: #6B7280;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-style: italic;
}

/* ============================================
   VIEW PRACTICE MODAL STYLES
   ============================================ */

.view-practice-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.view-practice-modal {
    width: 920px;
    height: 493px;
    max-height: 90vh;
    background: #FFFFFF;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.view-practice-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 10;
}

.view-practice-modal-close:hover {
    color: #374151;
}

.view-practice-modal-close:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 24px 24px 20px 24px;
}

.view-practice-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    border-radius: 7px;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    box-shadow: 0px 0.88px 1.75px -0.44px #0000001A, 0px 1.75px 5.25px 0px #00000026;
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-practice-icon img {
    width: 18px;
    height: 18px;
    filter: brightness(0) invert(1);
}

.view-practice-title-block h2 {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 20px;
    line-height: 28px;
    color: #111827;
    margin: 0 0 2px 0;
}

.view-practice-title-block p {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #6B7280;
    margin: 0;
}

.view-practice-body {
    flex: 1;
    padding: 0 24px 24px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.view-practice-field-row {
    display: flex;
    gap: 24px;
    width: 100%;
}

.view-practice-field-row.two-column {
    justify-content: space-between;
    max-width: 750px;
}

.view-practice-field-row.two-column .view-practice-field-group {
    flex: 0 0 calc((100% - 24px) / 2);
}

.view-practice-field-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.view-practice-field-group.full {
    flex: 0 0 100%;
}

.view-practice-field-group label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.view-practice-input {
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    width: 100%;
    box-sizing: border-box;
}

.view-practice-input:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-input::placeholder {
    color: #9CA3AF;
}

.view-practice-input[readonly] {
    background: #F3F4F6;
    cursor: default;
}

.view-practice-field-row.associated-ranches-row {
    justify-content: flex-start;
}

.view-practice-field-group.associated-ranches-group {
    max-width: 750px;
    width: 100%;
}

.view-practice-field-group.associated-ranches-group .associated-ranches-input {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 36px;
    background: #F9FAFB;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    padding: 0 12px;
    box-sizing: border-box;
}

.view-practice-field-group.associated-ranches-group .associated-ranch-input {
    border: none;
    background: transparent;
    padding: 0;
    height: 100%;
    color: #374151;
}

.view-practice-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.view-practice-select:disabled {
    background-color: #F3F4F6;
    cursor: default;
    opacity: 1;
}

.view-practice-date-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.view-practice-date-wrapper img {
    position: absolute;
    left: 14px;
    width: 16px;
    height: 16px;
    pointer-events: none;
}

.view-practice-date-wrapper input {
    padding-left: 40px;
}

.view-practice-table-section {
    margin-top: 8px;
}

.view-practice-table-title {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    margin-bottom: 12px;
}

.view-practice-table-box {
    width: 100%;
    max-height: 268.5px;
    border-radius: 11px;
    border: 2px solid #E5E7EB;
    background: transparent;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    overflow: hidden;
}

.view-practice-table-header {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    height: 42px;
    background: linear-gradient(180deg, #F9FAFB 0%, #F3F4F6 100%);
    border-bottom: 1px solid #E5E7EB;
    align-items: center;
    padding: 0 16px;
    box-sizing: border-box;
}

.view-practice-table-header span {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
}

.view-practice-table-row {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    width: 100%;
    min-height: 45px;
    padding: 10px 16px;
    box-sizing: border-box;
    align-items: center;
    border-bottom: 1px solid #F3F4F6;
}

.view-practice-table-row:last-child {
    border-bottom: none;
}

.view-practice-table-row span {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #374151;
    text-align: center;
}

.view-practice-table-row span:first-child {
    text-align: left;
}

/* View Practice Area Wrapper */
.view-practice-area-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.view-practice-area-wrapper .view-practice-input {
    padding-right: 40px;
}

.view-practice-area-wrapper .area-unit {
    position: absolute;
    right: 12px;
    font-size: 14px;
    color: #6B7280;
    font-weight: 500;
}

/* View Practice Alert Messages */
.view-practice-alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 16px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
}

.view-practice-alert.alert-success {
    background-color: #D1FAE5;
    color: #065F46;
    border: 1px solid #A7F3D0;
}

.view-practice-alert.alert-danger {
    background-color: #FEE2E2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

.view-practice-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 20px 0 12px;
    border-top: 1px solid #E5E7EB;
    margin-top: auto;
}

.view-practice-clear-btn {
    width: 77px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-practice-clear-btn:hover {
    background: #F9FAFB;
}

.view-practice-clear-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-edit-btn {
    width: 68px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #8EC5FF;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #1447E6;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-practice-edit-btn:hover {
    background: #F0F7FF;
}

.view-practice-edit-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-edit-btn img {
    width: 14px;
    height: 14px;
}

.view-practice-cancel-btn {
    width: 90px;
    height: 35px;
    border-radius: 7px;
    border: 2px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.view-practice-cancel-btn:hover {
    background: #F9FAFB;
}

.view-practice-cancel-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-save-btn {
    height: 35px;
    padding: 0 16px;
    border-radius: 7px;
    border: none;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.view-practice-save-btn:hover {
    background: #062540;
}

.view-practice-save-btn:focus {
    outline: none;
    box-shadow: none;
}

.view-practice-save-btn img {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

/* ========================================
   CREATE ACTIVITY MODAL STYLES
   ======================================== */

.create-activity-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.create-activity-modal {
    width: 850px;
    max-height: 652px;
    background: #FFFFFF;
    border-radius: 8px;
    border: 0.63px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: width 0.3s ease;
}

.create-activity-modal.expanded {
    width: 1589px;
}

.create-activity-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.create-activity-modal-close:hover {
    color: #111827;
}

.create-activity-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.create-activity-left {
    width: 850px;
    min-width: 850px;
    display: flex;
    flex-direction: column;
    border-right: none;
}

.create-activity-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 25px 25px 16px 25px;
    border-bottom: 1px solid #E5E7EB;
}

.create-activity-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 8.75px;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.create-activity-icon img {
    width: 21px;
    height: 21px;
    filter: brightness(0) invert(1);
}

.create-activity-title-block h2 {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 16px;
    line-height: 24px;
    color: #111827;
    margin: 0 0 4px 0;
}

.create-activity-title-block p {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #6B7280;
    margin: 0;
}

.create-activity-body {
    flex: 1;
    padding: 20px 25px;
    overflow-y: auto;
}

.create-activity-field-row {
    display: flex;
    gap: 20px;
    margin-bottom: 16px;
}

.create-activity-field-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.create-activity-field-group.full-width {
    flex: 1 0 100%;
}

.create-activity-field-group.half-width {
    flex: 0 0 calc(50% - 8px);
    max-width: calc(50% - 8px);
}

.create-activity-field-group label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.create-activity-right-label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    margin-bottom: 6px;
    display: block;
}

.create-activity-input {
    width: 100%;
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px 4px 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #111827;
    box-sizing: border-box;
}

    .create-activity-input:focus {
        outline: none;
        border-color: none;
    }

    .create-activity-input::placeholder {
        color: #6B7280;
    }

.create-activity-input:disabled {
    background: #F3F4F6;
    color: #6B7280;
    cursor: not-allowed;
}

.create-activity-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
    cursor: pointer;
    color: #6B7280;
}

.create-activity-select.has-value {
    color: #111827;
}

.create-activity-bonus-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.create-activity-bonus-wrapper .bonus-prefix {
    position: absolute;
    left: 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #6B7280;
}

.create-activity-bonus-wrapper .bonus-input {
    padding-left: 24px;
    width: 100%;
}

/* Activity Type Multi-Select Wrapper */
.activity-type-multi-select-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.activity-type-selected-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 0;
}

.activity-type-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    width: auto;
    height: 25px;
    padding: 4px 8px;
    border-radius: 6px;
    border: 0.67px solid #000000;
    background: #E6F0F7;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
    color: #083050;
}

.activity-type-tag-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #083050;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    padding: 2px;
    line-height: 1;
}

.activity-type-tag-remove:hover {
    background: rgba(8, 48, 80, 0.1);
}

.create-activity-checkbox-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 16px;
    padding-top: 16px;
}

.create-activity-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.create-activity-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1px solid #D1D5DB;
    cursor: pointer;
    accent-color: #083050;
}

.create-activity-checkbox-label span {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.create-activity-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10.5px;
    padding: 16px 25px;
    border-top: 1px solid #E5E7EB;
    margin-top: auto;
}

.create-activity-clear-btn {
    width: 77px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.create-activity-clear-btn:hover {
    background: #F9FAFB;
}

.create-activity-edit-btn {
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    border: 1px solid #1570EF;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #1570EF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.create-activity-edit-btn:hover {
    background: #EFF8FF;
}

.create-activity-edit-btn img {
    width: 14px;
    height: 14px;
}

.create-activity-save-btn {
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    border: none;
    background: #083050;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.create-activity-save-btn:hover {
    background: #083050;
}

.create-activity-save-btn img {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

.create-activity-alert {
    width: 100%;
    margin: 16px 0 0 0;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    border-radius: 6px;
    padding: 10px 14px;
    text-align: center;
}

.create-activity-alert.alert-success {
    background: #D1FAE5;
    color: #065F46;
}

.create-activity-alert.alert-danger {
    background: #FEE2E2;
    color: #991B1B;
}

/* Right Side - Pack Type Selection */
.create-activity-right {
    width: 663px;
    padding: 53px 25px 25px 25px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-height: 480px;
    overflow-y: auto;
}

.pack-type-title {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 14px;
    color: #111827;
}

.pack-type-box {
    width: 100%;
    max-width: 663px;
    border-radius: 8px;
    border: 0.67px solid #E5E7EB;
    border-top: 0.67px solid #E5E7EB;
    background: #FFFFFF;
    box-shadow: 0px 1px 2px -1px rgba(0, 0, 0, 0.1), 0px 1px 3px rgba(0, 0, 0, 0.1);
    padding: 0.67px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.pack-type-header {
    display: grid;
    grid-template-columns: 1fr 300px;
    height: 48px;
    background: #FFFFFF;
    border-bottom: 0.67px solid #C2C2C2;
    align-items: center;
    padding: 0 24px;
}

.pack-type-header span {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 16px;
    line-height: 24px;
    color: #111827;
}

.pack-type-rows-wrapper {
    max-height: 360px;
    overflow-y: auto;
}

.pack-type-row {
    display: grid;
    grid-template-columns: 1fr 300px;
    min-height: 65px;
    align-items: center;
    padding: 0 24px;
    border-bottom: 0.67px solid #E5E7EB;
}

.pack-type-row:last-child {
    border-bottom: none;
}

.pack-type-name {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 24px;
    color: #374151;
}

.pack-type-weight {
    display: flex;
    justify-content: flex-start;
}

.weight-input {
    width: 200px;
    height: 40px;
    border-radius: 8px;
    border: 0.67px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px 4px 32px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 100%;
    color: #6B7280;
    box-sizing: border-box;
}

.weight-input:disabled {
    background: #F9FAFB;
    color: #6B7280;
    cursor: default;
}

.pack-type-checkbox {
    display: flex;
    justify-content: center;
}

.pack-type-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 1px solid #D1D5DB;
    cursor: pointer;
    accent-color: #083050;
}

.pack-type-rate {
    display: flex;
    justify-content: flex-end;
}

.rate-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 200px;
}

.rate-input-wrapper .rate-prefix {
    position: absolute;
    left: 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #6B7280;
}

.rate-input {
    width: 100%;
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px 4px 32px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #111827;
    box-sizing: border-box;
}

    .rate-input:focus {
        outline: none;
        border-color: none;
    }

.rate-input:disabled {
    background: #F3F4F6;
    color: #6B7280;
    cursor: not-allowed;
}

.pack-type-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
}

.create-pack-type-btn {
    width: 171px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: #083050;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.create-pack-type-btn:hover {
    background: #062540;
}

.create-pack-type-btn span {
    font-size: 16px;
}

/* ========================================
   CREATE PACK TYPE MODAL STYLES
   ======================================== */

.create-packtype-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999 !important;
}

.create-packtype-modal {
    width: 920px;
    height: 459px;
    background: #FFFFFF;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.create-packtype-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.create-packtype-modal-close:hover {
    color: #111827;
}

.create-packtype-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 25px 25px 16px 25px;
    border-bottom: 1px solid #E5E7EB;
}

.create-packtype-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 8.75px;
    background: linear-gradient(180deg, #083050 0%, #083050 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.create-packtype-icon img {
    width: 21px;
    height: 21px;
    filter: brightness(0) invert(1);
}

.create-packtype-title-block h2 {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 16px;
    line-height: 24px;
    color: #111827;
    margin: 0 0 4px 0;
}

.create-packtype-title-block p {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #6B7280;
    margin: 0;
}

.create-packtype-body {
    padding: 20px 25px;
}

.create-packtype-field-row {
    display: flex;
    gap: 20px;
    margin-bottom: 16px;
}

.create-packtype-field-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.create-packtype-field-group label {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
}

.create-packtype-input {
    width: 100%;
    height: 40px;
    border-radius: 8px;
    border: 0.63px solid #D1D5DB;
    background: #F9FAFB;
    padding: 4px 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #111827;
    box-sizing: border-box;
}

    .create-packtype-input:focus {
        outline: none;
        border-color: none;
    }

    .create-packtype-input::placeholder {
        color: none;
    }

.create-packtype-input:disabled {
    background: #F3F4F6;
    color: #6B7280;
    cursor: not-allowed;
}

.create-packtype-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%236B7280' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
    cursor: pointer;
}

.create-packtype-size-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.create-packtype-size-wrapper .create-packtype-input {
    padding-right: 30px;
}

.create-packtype-size-wrapper .size-unit {
    position: absolute;
    right: 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #6B7280;
}

.create-packtype-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10.5px;
    padding: 16px 25px;
    border-top: 1px solid #E5E7EB;
}

.create-packtype-clear-btn {
    width: 77px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid #E5E7EB;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #111827;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.create-packtype-clear-btn:hover {
    background: #F9FAFB;
}

.create-packtype-edit-btn {
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    border: 1px solid #1570EF;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #1570EF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.create-packtype-edit-btn:hover {
    background: #EFF8FF;
}

.create-packtype-edit-btn img {
    width: 14px;
    height: 14px;
}

.create-packtype-save-btn {
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    border: none;
    background: #083050;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12.25px;
    line-height: 17.5px;
    color: #FFFFFF;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.create-packtype-save-btn:hover {
    background: #083050;
}

.create-packtype-save-btn img {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

.create-packtype-alert {
    width: 100%;
    margin: 16px 0 0 0;
    font-family: Inter, sans-serif;
    font-size: 14px;
    line-height: 20px;
    border-radius: 6px;
    padding: 10px 14px;
}

.create-packtype-alert.alert-success {
    background: #D1FAE5;
    color: #065F46;
}

.create-packtype-alert.alert-danger {
    background: #FEE2E2;
    color: #991B1B;
}

/* ========================================
   RESPONSIVE MEDIA QUERIES
   ======================================== */

/* Extra Large Screens (1400px and above) */
@media (min-width: 1400px) {
    .farms-container {
        max-width: 1400px;
    }
    
    .create-activity-modal.expanded {
        width: 1589px;
    }
}

/* Large Screens (1200px - 1399px) - Handled by comprehensive media query at 1400px */

/* Medium Screens (992px - 1199px) */
@media (max-width: 1199px) {
    .farms-search-container {
        flex-direction: column;
        gap: 16px;
    }
    
    .farms-filter-section {
        flex-wrap: wrap;
        width: 100%;
    }
    
    .farms-action-section {
        width: 100%;
        justify-content: flex-start;
    }
    
    .create-ranch-modal,
    .create-practice-modal,
    .view-practice-modal {
        width: 95vw;
        max-width: 850px;
    }
    
    .create-packtype-modal {
        width: 95vw;
        max-width: 920px;
    }
    
    .create-activity-modal {
        width: 95vw;
        max-width: 850px;
    }
    
    .create-activity-modal.expanded {
        width: 95vw;
        flex-direction: column;
        height: auto;
        max-height: 90vh;
    }
    
    .create-activity-left,
    .create-activity-right {
        width: 100%;
        min-width: auto;
        border-right: none;
    }
    
    .create-activity-right {
        border-top: 1px solid #E5E7EB;
        padding-top: 20px;
        max-height: none;
        overflow-y: visible;
    }
}

/* Tablet Screens (768px - 991px) */
@media (max-width: 991px) {
    .farms-page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .farms-tabs {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .farms-tab {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .farms-filter-group {
        flex: 1 1 calc(50% - 10px);
        min-width: 150px;
    }
    
    .table-header,
    .table-row {
        font-size: 13px;
    }
    
    .table-cell {
        padding: 10px 8px;
    }
    
    .create-ranch-field-row,
    .create-practice-field-row,
    .create-activity-field-row,
    .create-packtype-field-row {
        flex-direction: column;
        gap: 12px;
    }
    
    .create-ranch-field-group,
    .create-practice-field-group,
    .create-activity-field-group,
    .create-packtype-field-group {
        width: 100%;
    }
    
    .pack-type-box {
        height: auto;
        max-height: 400px;
    }
}

/* Small Tablet / Large Mobile (576px - 767px) */
@media (max-width: 767px) {
    .farms-container {
        padding: 0 12px;
    }
    
    .farms-header-title {
        font-size: 20px;
    }
    
    .farms-filter-section {
        flex-direction: column;
    }
    
    .farms-filter-group {
        width: 100%;
        flex: none;
    }
    
    .farms-search-input-wrapper {
        width: 100%;
    }
    
    .farms-create-button {
        width: 100%;
        justify-content: center;
    }
    
    .farms-table {
        overflow-x: auto;
    }
    
    .table-header,
    .table-row {
        min-width: 700px;
    }
    
    .create-ranch-modal,
    .create-practice-modal,
    .view-practice-modal,
    .create-activity-modal,
    .create-packtype-modal {
        width: 95vw;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .create-ranch-header,
    .create-practice-header,
    .create-activity-header,
    .create-packtype-header {
        padding: 16px;
    }
    
    .create-ranch-body,
    .create-practice-body,
    .create-activity-body,
    .create-packtype-body {
        padding: 16px;
    }
    
    .create-ranch-footer,
    .create-practice-footer,
    .create-activity-footer,
    .create-packtype-footer {
        padding: 12px 16px;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .view-ranch-modal,
    .view-allocations-modal {
        width: 95vw;
        max-height: 90vh;
    }
    
    .pack-type-header,
    .pack-type-row {
        grid-template-columns: 1.5fr 0.8fr 1fr;
        padding: 8px 12px;
    }
    
    .rate-input-wrapper {
        width: 100%;
    }
}

/* Mobile Screens (below 576px) */
@media (max-width: 575px) {
    .farms-container {
        padding: 0 8px;
    }
    
    .farms-page-header {
        padding: 12px 0;
    }
    
    .farms-header-title {
        font-size: 18px;
    }
    
    .farms-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 8px;
    }
    
    .farms-tab {
        white-space: nowrap;
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .table-cell {
        padding: 8px 6px;
        font-size: 12px;
    }
    
    .header-cell {
        font-size: 12px;
    }
    
    .farms-status-active,
    .farms-status-inactive {
        padding: 2px 8px;
        font-size: 11px;
    }
    
    .farms-action-enabled,
    .farms-action-disabled {
        padding: 4px 10px;
        font-size: 11px;
    }
    
    .create-ranch-modal,
    .create-practice-modal,
    .view-practice-modal,
    .create-activity-modal,
    .create-packtype-modal {
        width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .create-ranch-title-block h2,
    .create-practice-title-block h2,
    .create-activity-title-block h2,
    .create-packtype-title-block h2 {
        font-size: 14px;
    }
    
    .create-ranch-title-block p,
    .create-practice-title-block p,
    .create-activity-title-block p,
    .create-packtype-title-block p {
        font-size: 12px;
    }
    
    .create-ranch-input,
    .create-practice-input,
    .create-activity-input,
    .create-packtype-input {
        height: 36px;
        font-size: 13px;
    }
    
    .create-ranch-clear-btn,
    .create-ranch-save-btn,
    .create-practice-clear-btn,
    .create-practice-save-btn,
    .create-activity-clear-btn,
    .create-activity-save-btn,
    .create-packtype-clear-btn,
    .create-packtype-save-btn {
        height: 36px;
        font-size: 12px;
    }
    
    .create-activity-checkbox-row {
        flex-direction: column;
        gap: 12px;
    }
    
    .pack-type-header span,
    .pack-type-name {
        font-size: 13px;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 4px;
    }
    
    .pagination button {
        padding: 4px 8px;
        font-size: 12px;
    }
}

/* ========== NEW FARMS UI STYLES ========== */

/* New Tab Container */
.farms-tab-container-new {
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB80;
    border-radius: 12px;
    padding: 12.62px 12.62px 0.63px 12.62px;
    margin-bottom: 16px;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
}

.farms-tab-strip-new {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 12px;
}

.farms-tab-item-new {
    padding: 8px 24px;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.farms-tab-item-new:hover {
    background: rgba(8, 48, 80, 0.1);
}

.farms-tab-item-new.active {
    background: #083050;
    color: #FFFFFF;
}

/* New Search Container */
.farms-search-container-new {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB80;
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    margin-bottom: 16px;
    overflow: visible;
    position: relative;
    z-index: 10;
}

.farms-filter-section-new {
    display: flex;
    gap: 24px;
    align-items: flex-end;
}

.farms-filter-dropdown-new {
    width: 296px;
    height: 40px;
    padding: 8px 12px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    background-color: #F9FAFB;
    -webkit-appearance: none;
    appearance: none;
    background-image: url('/images/chevron-down.svg');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    cursor: pointer;
}

.farms-action-section-new {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}

/* Column Toggle Button */
.farms-column-toggle-btn {
    width: 48px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid #D1D5DB;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    transition: background-color 0.15s ease;
}

.farms-column-toggle-btn:hover {
    background-color: #F3F4F6;
}

.column-toggle-icon {
    width: 20px;
    height: 20px;
}

/* Column Visibility Dropdown */
.column-visibility-dropdown {
    position: absolute;
    top: 48px;
    right: 0;
    width: 261px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 12px;
    box-shadow: 0px 25px 50px -12px #00000040;
    z-index: 100;
    padding: 12px 0;
    pointer-events: auto;
}

.column-visibility-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    cursor: pointer;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
}

.column-visibility-item:hover {
    background-color: #F9FAFB;
}

.column-visibility-checkbox {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border-radius: 4px;
    border: 1px solid #083050;
    accent-color: #083050;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-color: #FFFFFF;
    position: relative;
}

.column-visibility-checkbox:checked {
    background-color: #083050;
    border-color: #083050;
}

.column-visibility-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FFFFFF;
    font-size: 14px;
    font-weight: bold;
}

.column-visibility-footer {
    border-top: 0.63px solid #E5E7EB;
    padding: 12px 16px;
    margin-top: 8px;
    display: flex;
    justify-content: flex-end;
}

.column-visibility-clear-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 8px 16px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 8px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #111827;
    cursor: pointer;
}

.column-visibility-clear-btn:hover {
    background-color: #F3F4F6;
}

/* New Table Styles */
.farms-table-new {
    background: #FFFFFF;
    border: 0.63px solid #DADADA;
    border-radius: 10px;
    box-shadow: 0px 1px 2px -1px #0000001A, 0px 1px 3px 0px #0000001A;
    overflow: hidden;
    position: relative;
}

.farms-table-header-new {
    display: flex;
    background: #FFFFFF;
    border-bottom: 1px solid #E5E7EB;
    padding: 0;
}

.table-column-prefs-cell {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 48px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    pointer-events: none;
}

.table-column-toggle-btn {
    width: 100%;
    height: 100%;
    padding: 0;
    border-radius: 10px;
    border: 1px solid #D1D5DB;
    background-color: #FFFFFF;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    pointer-events: auto;
}

.table-column-toggle-btn:hover {
    border-color: #9CA3AF;
}

.table-column-toggle-btn:focus {
    outline: none;
    box-shadow: none;
}

.table-column-prefs-cell .column-visibility-dropdown {
    top: calc(100% + 8px);
    right: 0;
}

.farms-header-cell-new {
    flex: 1;
    padding: 16px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: flex-start;
    cursor: pointer;
    text-align: left;
}

.farms-header-cell-new.expand-col {
    flex: 0 0 50px;
    cursor: default;
}

.farms-header-cell-new.sortable-header {
    cursor: pointer;
    user-select: none;
}

.farms-table-row-new {
    display: flex;
    border-bottom: 1px solid #E5E7EB;
    transition: background 0.2s ease;
    min-height: 64px;
    cursor: pointer;
}

.farms-table-row-new:hover {
    background: #F9FAFB;
}

.farms-table-row-new.expanded {
    background: #F9FAFB;
}

/* Disable row interactions when dropdown is open */
.farms-table-new.dropdown-open .farms-table-row-new {
    pointer-events: none;
    cursor: default;
}

.farms-table-new.dropdown-open .farms-table-row-new:hover {
    background: transparent;
}

.farms-row-cell-new {
    flex: 1;
    padding: 12px 16px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.farms-row-cell-new.expand-col {
    flex: 0 0 50px;
    justify-content: center;
}

.ranch-expand-arrow {
    width: 14px;
    height: 14px;
    border: none;
    border-radius: 2px;
    padding: 2px;
}

/* Fruit Variety Pills */
.fruit-variety-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 12px;
    border-radius: 10px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 12px;
    line-height: 20px;
    color: #000000;
    margin: 2px;
}

.pill-strawberry {
    background: #FFE2E2;
}

.pill-raspberry {
    background: #FCE7F3;
}

.pill-blueberry {
    background: #DBEAFE;
}

.pill-blackberry {
    background: #E9D5FF;
}

.pill-nonharvest {
    background: #FEF3C7;
    color: #92400E;
    font-weight: 500;
    border-radius: 9999px;
    padding: 2px 8px;
}

.pill-default {
    background: #F3F4F6;
}

/* New Status Badges */
.farms-status-active-new {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 53px;
    height: 21px;
    padding: 0 8px;
    background-color: #DCFCE7;
    color: #016630;
    border-radius: 6px;
    border: none;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
}

.farms-status-inactive-new {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    height: 21px;
    padding: 0 8px;
    background-color: #E5E7EB;
    color: #374151;
    border-radius: 6px;
    border: none;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
}

/* New Action Buttons */
.farms-action-enabled-new {
    min-width: 86px;
    height: 32px;
    border-radius: 6px;
    border: none;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background-color: #DCFCE7;
    color: #016630;
}

.farms-action-enabled-new:hover {
    background-color: #BBF7D0;
}

.farms-action-disabled-new {
    min-width: 90px;
    height: 32px;
    border-radius: 6px;
    border: none;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background-color: #F3F4F6;
    color: #1F2937;
}

.farms-action-disabled-new:hover {
    background-color: #E5E7EB;
}

/* Expanded Row Details */
.ranch-expanded-details {
    background: #FFFFFF;
    box-shadow: 0px 2px 4px 0px #0000000D inset;
    padding: 24px 24px 24px 56px;
    border-bottom: 1px solid #E5E7EB;
}

.practices-details-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.practices-details-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
}

.practices-expand-btn {
    margin-left: 0;
}

.create-practice-inline-btn {
    margin-left: 0;
}

.practices-details-title {
    font-family: Inter, sans-serif;
    font-weight: 700;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #6B7280;
}

.practices-expand-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #FFFFFF;
    border: 1px solid #083050;
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: background-color 0.15s ease;
}

.practices-expand-btn:hover {
    background-color: #F0F5FA;
}

.practices-expand-icon {
    width: 16px;
    height: 16px;
}

.create-practice-inline-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 32px;
    padding: 6px 12px;
    background: #083050;
    border: none;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: #FFFFFF;
    cursor: pointer;
    margin-left: 0;
}

.create-practice-inline-btn:hover {
    background: #0a3d66;
}

/* Inner Practices Table */
.practices-inner-table {
    width: 100%;
    background: #FFFFFF;
    border: 1px solid #083050;
    border-radius: 6px;
    overflow: hidden;
    box-sizing: border-box;
}

/* Nested table showing count */
.nested-showing-count {
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    line-height: 20px;
    color: #4B5563;
    text-align: right;
    padding: 8px 12px;
    background: #F9FAFB;
    border-top: 1px solid #E5E7EB;
}

.practices-inner-header {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr 0.8fr 1fr 1fr 0.8fr 0.9fr 0.35fr;
    background: #083050;
    border-bottom: 0.67px solid #083050;
}

.practices-inner-header .practices-inner-cell {
    height: 32px;
    padding: 6px 16px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #FFFFFF;
    display: flex;
    align-items: center;
}

.practices-inner-body {
    scrollbar-gutter: stable both-edges;
}

.practices-inner-row {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr 0.8fr 1fr 1fr 0.8fr 0.9fr 0.35fr;
    border-bottom: 1px solid #E5E7EB;
    height: 56px;
    align-items: center;
}

.practices-inner-row:last-child {
    border-bottom: none;
}

.practices-inner-cell {
    padding: 12px 16px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #111827;
    display: flex;
    align-items: center;
}

.practices-inner-cell.practice-code-cell {
    font-weight: 500;
    color: #111827;
}

.practice-delete-cell {
    justify-content: center;
}

.practice-inline-delete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 27px;
    height: 23px;
    padding: 5px;
    border-radius: 3px;
    border: 1px solid #FCA5A5;
    background: #FEE2E2;
    cursor: pointer;
}

.practice-inline-delete-btn img {
    width: 12px;
    height: 12px;
}

/* Practices Overlay Modal */
.practices-overlay-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.25);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.practices-overlay-modal {
    width: 1000px;
    max-width: 95vw;
    max-height: 90vh;
    height: auto;
    background: #FFFFFF;
    border-radius: 8px;
    box-shadow: 0px 25px 50px -12px #00000040;
    display: flex;
    flex-direction: column;
}

.practices-overlay-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #E5E7EB;
}

.practices-overlay-title-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.practices-overlay-title {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 22px;
    line-height: 30.8px;
    color: #083050;
}

.practices-overlay-subtitle {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #6B7280;
}

.practices-overlay-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.practices-overlay-search-wrapper {
    position: relative;
    width: 294px;
}

.practices-overlay-search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    opacity: 0.5;
}

.practices-overlay-search-input {
    width: 100%;
    height: 36px;
    padding: 4px 12px 4px 40px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    border: 0.67px solid #D1D5DB;
    border-radius: 8px;
    background-color: #F9FAFB;
}

.practices-overlay-search-input::placeholder {
    color: #6B7280;
}

.create-practice-overlay-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 36px;
    padding: 8px 16px;
    background: #083050;
    border: none;
    border-radius: 8px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #FFFFFF;
    cursor: pointer;
}

.create-practice-overlay-btn:hover {
    background: #0a3d66;
}

.practices-overlay-close {
    position: relative;
    width: 24px;
    height: 24px;
    background: transparent;
    border: none;
    font-size: 20px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 16px;
}

.practices-overlay-close:hover {
    color: #111827;
}

.practices-overlay-body {
    flex: 0 0 auto;
    padding: 24px;
    background: #F9FAFB;
    overflow-y: auto;
}

.practices-overlay-table {
    width: 100%;
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    overflow: hidden;
}

.practices-overlay-table-header {
    display: grid;
    grid-template-columns: 1fr 1.6fr 1fr 0.6fr 1fr 1fr 0.7fr 1.2fr;
    background: #083050;
    border-bottom: 1px solid #083050;
    padding-right: 79px;
}

.practices-overlay-table-header .practices-overlay-cell {
    padding: 14px 12px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 11px;
    line-height: 16px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #FFFFFF;
}

.practices-overlay-table-body {
    max-height: 400px;
    overflow-y: auto;
}

.practices-overlay-row {
    display: grid;
    grid-template-columns: 1fr 1.6fr 1fr 0.6fr 1fr 1fr 0.7fr 1.2fr;
    border-bottom: 1px solid #F3F4F6;
    align-items: center;
}

.practices-overlay-row:last-child {
    border-bottom: none;
}

.practices-overlay-cell {
    padding: 12px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 13px;
    line-height: 20px;
    color: #4B5563;
    display: flex;
    align-items: center;
}

.practices-overlay-cell.practice-code-cell {
    font-weight: 500;
    color: #111827;
}

.practices-overlay-cell.practices-overlay-action-cell {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.practices-overlay-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0;
    background: #FFFFFF;
    border-top: 1px solid #E5E7EB;
}

.practices-overlay-footer .pagination-container {
    width: 100%;
    border-top: none;
}

.practices-overlay-showing {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #4B5563;
}

.practices-overlay-pagination {
    display: flex;
    align-items: center;
    gap: 8px;
}

.practices-overlay-page-btn {
    width: 32px;
    height: 32px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.practices-overlay-page-btn:hover:not(:disabled) {
    background: #F3F4F6;
}

.practices-overlay-page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.practices-overlay-page-info {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #4B5563;
    padding: 0 8px;
}

/* ==================== Activity Types Overlay Modal (6 columns) ==================== */
.activity-types-overlay-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.25);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.activity-types-overlay-modal {
    width: 900px;
    max-width: 95vw;
    max-height: 90vh;
    background: #FFFFFF;
    border-radius: 8px;
    box-shadow: 0px 25px 50px -12px #00000040;
    display: flex;
    flex-direction: column;
}

.activity-types-overlay-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #E5E7EB;
}

.activity-types-overlay-title-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.activity-types-overlay-title {
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 18px;
    line-height: 24px;
    color: #083050;
}

.activity-types-overlay-subtitle {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #6B7280;
}

.activity-types-overlay-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.activity-types-overlay-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.activity-types-overlay-search-icon {
    position: absolute;
    left: 12px;
    width: 16px;
    height: 16px;
    pointer-events: none;
}

.activity-types-overlay-search-input {
    width: 200px;
    height: 36px;
    padding: 8px 12px 8px 36px;
    border: 1px solid #D1D5DB;
    border-radius: 8px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #111827;
    background: #FFFFFF;
}

.activity-types-overlay-search-input::placeholder {
    color: #9CA3AF;
}

.activity-types-overlay-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: #6B7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.activity-types-overlay-close:hover {
    color: #111827;
}

.activity-types-overlay-body {
    flex: 0 0 auto;
    padding: 24px;
    background: #F9FAFB;
    overflow-y: auto;
}

.activity-types-overlay-table {
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    overflow: hidden;
    width: 100%;
}

.activity-types-overlay-table-header {
    display: grid;
    grid-template-columns: 0.8fr 2fr 1.5fr 0.8fr 0.8fr 1fr;
    background: #083050;
}

.activity-types-overlay-table-header .activity-types-overlay-cell {
    padding: 12px 16px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #FFFFFF;
}

.activity-types-overlay-table-body {
    max-height: 400px;
    overflow-y: auto;
}

.activity-types-overlay-row {
    display: grid;
    grid-template-columns: 0.8fr 2fr 1.5fr 0.8fr 0.8fr 1fr;
    border-bottom: 1px solid #F3F4F6;
}

.activity-types-overlay-row:last-child {
    border-bottom: none;
}

.activity-types-overlay-cell {
    padding: 12px 16px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #4B5563;
    display: flex;
    align-items: center;
}

.activity-types-overlay-cell.activity-type-code-cell {
    font-weight: 500;
    color: #111827;
}

.activity-types-overlay-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0;
    background: #FFFFFF;
    border-top: 1px solid #E5E7EB;
}

.activity-types-overlay-footer .pagination-container {
    width: 100%;
    border-top: none;
}

.activity-types-overlay-showing {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #4B5563;
}

.activity-types-overlay-pagination {
    display: flex;
    align-items: center;
    gap: 8px;
}

.activity-types-overlay-page-btn {
    width: 32px;
    height: 32px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    background: #FFFFFF;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.activity-types-overlay-page-btn:hover:not(:disabled) {
    background: #F3F4F6;
}

.activity-types-overlay-page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.activity-types-overlay-page-info {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #4B5563;
    padding: 0 8px;
}

/* Responsive Styles for New UI */
@media (max-width: 1200px) {
    .farms-search-container-new {
        flex-direction: column;
        align-items: stretch;
    }

    .farms-filter-section-new {
        flex-wrap: wrap;
    }

    .farms-action-section-new {
        justify-content: flex-end;
    }

    .practices-overlay-modal {
        width: 95vw;
    }

    .practices-inner-header,
    .practices-inner-row {
        grid-template-columns: repeat(8, minmax(80px, 1fr));
    }

    .practices-overlay-table {
        overflow-x: auto;
    }

    .practices-overlay-table-header,
    .practices-overlay-row {
        grid-template-columns: 1fr 1.5fr 1fr 0.7fr 1fr 1fr 0.8fr 1.2fr;
    }

    .activity-types-overlay-modal {
        width: 95vw;
    }

    .activity-types-overlay-table-header,
    .activity-types-overlay-row {
        grid-template-columns: repeat(6, minmax(80px, 1fr));
    }

    .activity-types-overlay-table {
        overflow-x: auto;
    }
}

@media (max-width: 768px) {
    .farms-tab-strip-new {
        flex-wrap: wrap;
    }

    .farms-tab-item-new {
        padding: 6px 16px;
        font-size: 13px;
    }

    .farms-filter-section-new {
        flex-direction: column;
        gap: 12px;
    }

    .farms-filter-dropdown-new {
        width: 100%;
    }

    .farms-search-input-wrapper {
        width: 100%;
    }

    .farms-table-new {
        overflow-x: auto;
    }

    .farms-table-header-new,
    .farms-table-row-new {
        min-width: 800px;
    }

    .ranch-expanded-details {
        padding: 16px;
    }

    .practices-inner-table {
        overflow-x: auto;
    }

    .practices-inner-header,
    .practices-inner-row {
        min-width: 700px;
    }

    .practices-overlay-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .practices-overlay-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .practices-overlay-search-wrapper {
        width: 100%;
    }

    .column-visibility-dropdown {
        right: -100px;
    }
}

@media (max-width: 576px) {
    .farms-tab-container-new {
        padding: 8px;
    }

    .farms-tab-item-new {
        padding: 6px 12px;
        font-size: 12px;
    }

    .farms-action-section-new {
        flex-direction: column;
        gap: 8px;
        width: 100%;
    }

    .farms-column-toggle-btn {
        width: 100%;
    }

    .farms-create-button {
        width: 100%;
        justify-content: center;
    }

    .practices-overlay-modal {
        width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .practices-overlay-footer {
        flex-direction: column;
        gap: 12px;
    }
}

/* ============================================
   PRACTICE OVERLAY STYLES (Figma Specs)
   Separate CSS to avoid affecting other overlays
   ============================================ */

/* Override backdrop for practice overlay */
.practices-overlay-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.25);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

/* Practice Overlay Modal - Figma specs */
.practices-overlay-modal {
    width: 1304px;
    max-width: 95vw;
    max-height: 90vh;
    height: auto;
    background: #FFFFFF;
    border-radius: 8px;
    border-top: 1px solid #E5E7EB;
    box-shadow: 0px 4px 6px -4px #0000001A, 0px 10px 15px -3px #0000001A;
    display: flex;
    flex-direction: column;
    opacity: 1;
}

/* Practice Overlay Table Container - Figma specs */
.practices-overlay-body {
    flex: 0 0 auto;
    padding: 25px;
    background: #FFFFFF;
    overflow-y: auto;
}

.practices-overlay-table {
    width: 1255px;
    max-width: 100%;
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    overflow: hidden;
    padding: 1px;
}

/* Practice Overlay Table Header - Figma specs */
.practices-overlay-table-header {
    display: grid;
    grid-template-columns: 137.78px 252.8px 119.75px 88.81px 108.16px 108.09px 110.06px 99.91px 1fr;
    width: 1253px;
    max-width: 100%;
    height: 49px;
    background: #083050;
    border-bottom: 1px solid #083050;
    align-items: center;
    padding: 0;
}

    .practices-overlay-table-header .practices-overlay-cell {
        padding: 0 12px;
        font-family: Inter, sans-serif;
        font-weight: 600;
        font-size: 12px;
        line-height: 16px;
        letter-spacing: 0.6px;
        text-transform: uppercase;
        color: #FFFFFF;
        height: 48.5px;
        display: flex;
        align-items: center;
    }

/* Practice Overlay Table Body */
.practices-overlay-table-body {
    max-height: calc(635px - 49px);
    overflow-y: auto;
}

/* Practice Overlay Row - Figma specs */
.practices-overlay-row {
    display: grid;
    grid-template-columns: 137.78px 252.8px 119.75px 88.81px 108.16px 108.09px 110.06px 99.91px 1fr;
    width: 1253px;
    max-width: 100%;
    height: 65px;
    border-bottom: 1px solid #F3F4F6;
    align-items: center;
}

    .practices-overlay-row:last-child {
        border-bottom: none;
    }

/* Practice Overlay Cell - Figma specs */

.practices-overlay-cell {
    padding: 0 12px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0px;
    color: #4B5563;
    height: 65px;
    display: flex;
    align-items: center;
}

    .practices-overlay-cell.practice-code-cell {
        font-weight: 500;
        color: #111827;
    }

    /* Practice Overlay Action Cell */
    .practices-overlay-cell.practices-overlay-action-cell {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 8px;
        padding-right: 12px;
    }

    .practices-overlay-cell.practice-overlay-delete-cell {
        display: flex;
        justify-content: flex-end;
        align-items: center;
        padding-right: 25px;
    }

/* ============================================
   PRACTICE OVERLAY DELETE BUTTON - Figma specs
   New class to avoid affecting pack-type-delete-btn
   ============================================ */
.practice-overlay-delete-btn {
    width: 72px;
    height: 23px;
    border: 1px solid #DC2626;
    border-radius: 5px;
    padding: 5px;
    gap: 4px;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-sizing: border-box;
}

    .practice-overlay-delete-btn:hover {
        background: #FEF2F2;
    }

    .practice-overlay-delete-btn img {
        width: 18px;
        height: 18px;
    }

    .practice-overlay-delete-btn span,
    .practice-overlay-delete-btn {
        font-family: Inter, sans-serif;
        font-weight: 500;
        font-size: 12px;
        line-height: 100%;
        letter-spacing: 0px;
        color: #DC2626;
        vertical-align: middle;
    }

/* Responsive adjustments for practice overlay */
@media (max-width: 1400px) {
    .practices-overlay-modal {
        width: 95vw;
        height: auto;
        max-height: 90vh;
    }

    .practices-overlay-table {
        width: 100%;
        height: auto;
    }

    .practices-overlay-table-header,
    .practices-overlay-row {
        width: 100%;
        grid-template-columns: 1fr 1.6fr 1fr 0.7fr 0.9fr 0.9fr 0.8fr 0.8fr 1fr;
    }
}

@media (max-width: 1024px) {
    .practices-overlay-table-header,
    .practices-overlay-row {
        grid-template-columns: repeat(9, minmax(80px, 1fr));
    }

    .practices-overlay-table {
        overflow-x: auto;
    }
}

@media (max-width: 768px) {
    .practices-overlay-modal {
        width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .practices-overlay-row {
        height: auto;
        min-height: 65px;
    }

    .practices-overlay-cell {
        height: auto;
        min-height: 65px;
    }
}


/* ========== ACTIVITIES AND PACK TYPES TAB STYLES ========== */

/* Multi-Select Dropdown */
.activity-multi-select-wrapper {
    position: relative;
    width: 296px;
    min-width: 296px;
    z-index: 1000;
}

.activity-multi-select-btn {
    width: 100%;
    height: 40px;
    padding: 0 11.99px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #F9FAFB;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
    cursor: pointer;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.activity-multi-select-btn:hover {
    background: #F3F4F6;
}

.multi-select-count {
    color: #111827;
    padding: 2px 6px;
    border-radius: 4px;
    border: 1px solid #D1D5DB;
    font-size: 12px;
    font-weight: 500;
}

.dropdown-chevron {
    width: 12px;
    height: 12px;
    transition: transform 0.2s ease;
}

.activity-multi-select-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 220px;
    min-width: 200px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 8px;
    box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    padding: 8px 0;
    margin-top: 4px;
    max-height: 260px;
    overflow: hidden;
}

.activity-multi-select-dropdown::-webkit-scrollbar {
    width: 6px;
}

.activity-multi-select-dropdown::-webkit-scrollbar-track {
    background: transparent;
}

.activity-multi-select-dropdown::-webkit-scrollbar-thumb {
    background: #D1D5DB;
    border-radius: 999px;
}

.activity-multi-select-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    cursor: pointer;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #111827;
}

.activity-multi-select-item:hover {
    background: #F9FAFB;
}

.activity-checkbox {
    width: 18px;
    height: 18px;
    min-width: 18px;
    border-radius: 4px;
    border: 1px solid #083050;
    accent-color: #083050;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-color: #FFFFFF;
    position: relative;
}

.activity-checkbox:checked {
    background-color: #083050;
    border-color: #083050;
}

.activity-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FFFFFF;
    font-size: 12px;
    font-weight: bold;
}

.activity-multi-select-footer {
    border-top: 1px solid #E5E7EB;
    padding: 8px 16px;
    margin-top: 8px;
    display: flex;
    justify-content: flex-end;
}

.activity-multi-select-clear {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #FFFFFF;
    border: 0.63px solid #E5E7EB;
    border-radius: 8px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #111827;
    cursor: pointer;
    padding: 8px 16px;
    height: 40px;
}

.activity-multi-select-clear:hover {
    background-color: #F3F4F6;
}

/* Activity Group Dropdown Search */
.activity-dropdown-search-container {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-bottom: 1px solid #E5E7EB;
    margin-bottom: 4px;
}

.activity-dropdown-search-icon {
    width: 16px;
    height: 16px;
    opacity: 0.5;
}

.activity-dropdown-search-input {
    flex: 1;
    border: none;
    outline: none;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #111827;
    background: transparent;
}

.activity-dropdown-search-input::placeholder {
    color: #9CA3AF;
}

/* Activity Group "All" Option */
.activity-multi-select-all-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    cursor: pointer;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #111827;
    border-bottom: 1px solid #E5E7EB;
    margin-bottom: 4px;
}

.activity-multi-select-all-option:hover {
    background: #F9FAFB;
}

.activity-multi-select-all-option.selected {
    background: #EFF6FF;
    color: #083050;
}

.activity-check-icon {
    width: 16px;
    height: 16px;
}

/* Activity Group List Container */
.activity-multi-select-list {
    max-height: 180px;
    overflow-y: auto;
}

.activity-multi-select-list::-webkit-scrollbar {
    width: 6px;
}

.activity-multi-select-list::-webkit-scrollbar-track {
    background: transparent;
}

.activity-multi-select-list::-webkit-scrollbar-thumb {
    background: #D1D5DB;
    border-radius: 999px;
}

/* Activity Expanded Details */
.activity-expanded-details {
    background: #FFFFFF;
    box-shadow: 0px 2px 4px 0px #0000000D inset;
    padding: 24px 24px 24px 56px;
    border-bottom: 1px solid #E5E7EB;
}

.pack-types-details-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.pack-types-expand-btn {
    margin-left: auto;
}

.pack-types-details-title {
    font-family: Inter, sans-serif;
    font-weight: 700;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #6B7280;
}

.pack-types-expand-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #FFFFFF;
    border: 1px solid #083050;
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: background-color 0.15s ease;
}

.pack-types-expand-btn:hover {
    background-color: #F0F5FA;
}

.pack-types-expand-icon {
    width: 16px;
    height: 16px;
}

.add-pack-type-inline-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 32px;
    padding: 6px 12px;
    background: #083050;
    border: none;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: #FFFFFF;
    cursor: pointer;
    margin-left: auto;
}

.add-pack-type-inline-btn:hover {
    background: #0a3d66;
}

/* Pack Types Inner Table */
.pack-types-inner-table {
    background: #FFFFFF;
    border: 1px solid #083050;
    border-radius: 8px;
    overflow: hidden;
}

.pack-types-inner-header {
    display: grid;
    grid-template-columns: 0.8fr 1.5fr 1.5fr 0.8fr 0.8fr 0.8fr;
    background: #083050;
    border-bottom: 1px solid #083050;
}

.pack-types-inner-header .pack-types-inner-cell {
    padding: 8px 12px;
    font-family: Inter, sans-serif;
    font-weight: 600;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: #FFFFFF;
}

.pack-types-inner-body {
    max-height: 200px;
    overflow-y: auto;
}

.pack-types-inner-row {
    display: grid;
    grid-template-columns: 0.8fr 1.5fr 1.5fr 0.8fr 0.8fr 0.8fr;
    border-bottom: 1px solid #F3F4F6;
}

.pack-types-inner-row:last-child {
    border-bottom: none;
}

.pack-types-inner-cell {
    padding: 12px;
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    line-height: 20px;
    color: #4B5563;
    display: flex;
    align-items: center;
}

.pack-types-inner-cell.pack-code-cell {
    font-weight: 500;
    color: #083050;
}

.pack-type-delete-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #FFFFFF;
    border: 1px solid #DC2626;
    border-radius: 6px;
    font-family: Inter, sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: #DC2626;
    cursor: pointer;
}

.pack-type-delete-btn:hover {
    background: #FEE2E2;
}

.pack-type-delete-btn img {
    width: 14px;
    height: 14px;
}

/* Footer Styles */
.table-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
}

.footer-left {
    display: flex;
    align-items: center;
}

.showing-text {
    font-family: Inter, sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #6B7280;
}

/* Responsive Styles for Activities Tab */
@media (max-width: 1200px) {
    .activity-multi-select-wrapper {
        width: 180px;
    }

    .pack-types-inner-header,
    .pack-types-inner-row {
        grid-template-columns: repeat(6, minmax(80px, 1fr));
    }
}

@media (max-width: 768px) {
    .activity-multi-select-wrapper {
        width: 100%;
    }

    .activity-multi-select-dropdown {
        width: 100%;
    }

    .activity-expanded-details {
        padding: 16px;
    }

    .pack-types-inner-table {
        overflow-x: auto;
    }

    .pack-types-inner-header,
    .pack-types-inner-row {
        min-width: 600px;
    }
}

@media (max-width: 576px) {
    .table-footer {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .footer-right {
        width: 100%;
        justify-content: center;
    }
}

/* ========== COMPREHENSIVE RESPONSIVE FIXES FOR SMALLER SCREENS ========== */

/* 1400px and below - Common laptop screens */
@media (max-width: 1400px) {
    .farms-page {
        max-width: 100%;
        margin-right: 16px;
    }

    /* Modal fixes - ensure header/footer visible */
    .create-ranch-modal,
    .view-allocations-modal,
    .create-practice-modal,
    .view-practice-modal,
    .create-activity-modal {
        width: 90vw;
        max-width: 800px;
        max-height: 90vh;
    }

    .create-ranch-modal .create-ranch-body,
    .view-allocations-modal .view-allocations-body,
    .create-practice-modal .create-practice-body,
    .view-practice-modal .view-practice-body,
    .create-activity-modal .create-activity-body {
        overflow-y: auto;
        flex: 1;
        min-height: 0;
    }

    .create-ranch-modal .create-ranch-header,
    .view-allocations-modal .view-allocations-header,
    .create-practice-modal .create-practice-header,
    .view-practice-modal .view-practice-header,
    .create-activity-modal .create-activity-header {
        flex-shrink: 0;
    }

    .create-ranch-modal .create-ranch-footer,
    .view-allocations-modal .view-allocations-footer,
    .create-practice-modal .create-practice-footer,
    .view-practice-modal .view-practice-footer,
    .create-activity-modal .create-activity-footer {
        flex-shrink: 0;
    }

    /* Activity modal - not expanded (no activity types selected) */
    .create-activity-modal:not(.expanded) {
        width: 90vw;
        max-width: 700px;
    }

    .create-activity-modal:not(.expanded) .create-activity-left {
        width: 100%;
        min-width: unset;
    }

    /* Activity modal - expanded (activity types selected) */
    .create-activity-modal.expanded {
        width: 95vw;
        max-width: 1200px;
    }

    .create-activity-modal.expanded .create-activity-left {
        width: 55%;
        min-width: unset;
    }

    .create-activity-modal.expanded .create-activity-right {
        width: 45%;
        max-height: 480px;
        padding: 20px 15px;
    }

    /* Fix pack-type alignment for 1366px screens */
    .create-activity-modal.expanded .pack-type-box {
        max-width: 100%;
    }

    .create-activity-modal.expanded .pack-type-header,
    .create-activity-modal.expanded .pack-type-row {
        grid-template-columns: 1fr 120px;
        padding: 0 12px;
    }

    .create-activity-modal.expanded .pack-type-name {
        font-size: 14px;
        word-break: break-word;
        overflow-wrap: break-word;
    }

    .create-activity-modal.expanded .weight-input {
        width: 100px;
        padding: 4px 8px;
        font-size: 13px;
    }

    .view-allocations-table-box {
        width: 100%;
        max-width: 100%;
    }

    .view-allocations-table-header,
    .view-allocations-table-row {
        grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr;
        padding: 0 12px;
    }

    /* Activity multi-select */
    .activity-multi-select-wrapper {
        width: 220px;
        min-width: 180px;
    }

    /* Search input */
    .farms-search-input-wrapper {
        width: 240px;
    }
}

/* 1200px and below - Smaller laptops */
@media (max-width: 1200px) {
    .farms-page {
        margin-right: 12px;
    }

    /* Modal responsive */
    .create-ranch-modal {
        width: 95vw;
        max-width: 700px;
    }

    .create-ranch-body {
        padding: 16px 20px 0;
    }

    .create-ranch-field-row {
        flex-direction: column;
        gap: 16px;
    }

    .create-ranch-field-group,
    .create-ranch-field-group.full {
        flex: 1 1 100%;
        width: 100%;
    }

    /* Activity modal - not expanded */
    .create-activity-modal:not(.expanded) {
        width: 95vw;
        max-width: 600px;
    }

    .create-activity-modal:not(.expanded) .create-activity-left {
        width: 100%;
        min-width: unset;
    }

    /* Activity modal - expanded - stack vertically */
    .create-activity-modal.expanded {
        width: 95vw;
        max-width: 700px;
        max-height: 90vh;
    }

    .create-activity-modal.expanded .create-activity-content {
        flex-direction: column;
        overflow-y: auto;
    }

    .create-activity-modal.expanded .create-activity-left {
        width: 100%;
        min-width: unset;
    }

    .create-activity-modal.expanded .create-activity-right {
        width: 100%;
        border-left: none;
        border-top: 1px solid #E5E7EB;
        max-height: none;
    }

    /* View allocations modal */
    .view-allocations-modal {
        width: 95vw;
        max-width: 700px;
    }

    .view-allocations-body {
        padding: 16px 20px;
    }

    .view-allocations-field-row {
        flex-direction: column;
        gap: 12px;
    }

    .view-allocations-field-group {
        width: 100%;
    }

    /* Table box */
    .view-allocations-table-box {
        width: 100%;
        overflow-x: auto;
    }

    .view-allocations-table-header,
    .view-allocations-table-row {
        min-width: 500px;
        grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
    }

    /* Practices overlay */
    .practices-overlay-modal {
        width: 95vw;
        max-width: 900px;
    }

    /* Filter section */
    .farms-filter-section-new {
        gap: 12px;
    }

    .farms-filter-dropdown-new {
        width: 180px;
    }
}

/* 992px and below - Tablets */
@media (max-width: 992px) {
    .farms-page {
        margin-right: 8px;
        padding-bottom: 80px;
    }

    /* Search and filter layout */
    .farms-search-container-new {
        flex-direction: column;
        gap: 16px;
    }

    .farms-filter-section-new {
        width: 100%;
        flex-wrap: wrap;
    }

    .farms-action-section-new {
        width: 100%;
        justify-content: space-between;
    }

    /* Modals full width */
    .create-ranch-modal,
    .view-allocations-modal {
        width: 95vw;
        max-width: none;
        margin: 16px;
    }

    /* Activity modal - all states */
    .create-activity-modal,
    .create-activity-modal:not(.expanded),
    .create-activity-modal.expanded {
        width: 95vw;
        max-width: none;
        margin: 16px;
        max-height: 90vh;
    }

    .create-activity-modal .create-activity-content {
        flex-direction: column;
        overflow-y: auto;
    }

    .create-activity-modal .create-activity-left {
        width: 100%;
        min-width: unset;
    }

    .create-activity-modal .create-activity-right {
        width: 100%;
        border-left: none;
        border-top: 1px solid #E5E7EB;
        max-height: none;
    }

    .create-ranch-header,
    .view-allocations-header {
        padding: 16px;
    }

    .create-ranch-footer,
    .view-allocations-footer {
        padding: 16px;
        flex-wrap: wrap;
        gap: 12px;
    }

    /* Checkboxes row */
    .create-ranch-checkbox-row {
        flex-wrap: wrap;
        gap: 16px;
    }

    /* Practices overlay */
    .practices-overlay-modal {
        width: 98vw;
        max-height: 90vh;
    }

    .practices-overlay-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .practices-overlay-actions {
        flex-wrap: wrap;
        gap: 8px;
    }

    /* Table responsive */
    .farms-table-new {
        overflow-x: auto;
    }

    .farms-table-header-new,
    .farms-table-row-new {
        min-width: 900px;
    }

    /* Activities table */
    .activities-table-new {
        overflow-x: auto;
    }

    .activities-table-header-new,
    .activities-table-row-new {
        min-width: 800px;
    }
}

/* 768px and below - Small tablets / Large phones */
@media (max-width: 768px) {
    .farms-page {
        margin-right: 4px;
        padding-bottom: 60px;
    }

    /* Page header */
    .farms-page-header {
        margin-bottom: 12px;
    }

    .farms-page-title {
        font-size: 16px;
    }

    /* Tabs */
    .farms-tab-container-new {
        padding: 8px 12px;
    }

    .farms-tab-strip-new {
        gap: 8px;
    }

    .farms-tab-item-new {
        padding: 8px 16px;
        font-size: 13px;
    }

    /* Filter section */
    .farms-filter-section-new {
        flex-direction: column;
        align-items: stretch;
    }

    .farms-search-input-wrapper,
    .farms-filter-dropdown-new,
    .activity-multi-select-wrapper {
        width: 100%;
        min-width: unset;
    }

    /* Action buttons */
    .farms-action-section-new {
        flex-direction: column;
        gap: 8px;
    }

    .farms-column-toggle-btn,
    .farms-create-button {
        width: 100%;
        justify-content: center;
    }

    /* Modals */
    .create-ranch-modal,
    .view-allocations-modal {
        width: 100vw;
        max-width: 100vw;
        max-height: 100vh;
        margin: 0;
        border-radius: 0;
    }

    .create-ranch-modal-close {
        top: 16px;
        right: 16px;
    }

    .create-ranch-header {
        padding: 16px;
        gap: 12px;
    }

    .create-ranch-title-block h2 {
        font-size: 18px;
    }

    .create-ranch-body {
        padding: 12px 16px;
        gap: 16px;
    }

    .create-ranch-footer {
        padding: 12px 16px;
    }

    .create-ranch-footer button {
        padding: 10px 20px;
        font-size: 13px;
    }

    /* Practices overlay full screen */
    .practices-overlay-modal {
        width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .practices-overlay-search-wrapper {
        width: 100%;
    }

    /* Table allocations */
    .view-allocations-table-box {
        border-radius: 8px;
    }

    .view-allocations-table-header,
    .view-allocations-table-row {
        min-width: 450px;
        font-size: 11px;
        padding: 0 8px;
    }

    /* Expanded details */
    .ranch-expanded-details,
    .activity-expanded-details {
        padding: 12px;
    }

    .practices-inner-table,
    .pack-types-inner-table {
        overflow-x: auto;
    }

    .practices-inner-header,
    .practices-inner-row,
    .pack-types-inner-header,
    .pack-types-inner-row {
        min-width: 650px;
    }

    /* Column visibility dropdown */
    .column-visibility-dropdown {
        right: 0;
        left: auto;
        width: 200px;
    }

    /* Activity dropdown */
    .activity-multi-select-dropdown {
        width: 100%;
        max-width: 300px;
    }
}

/* 576px and below - Mobile phones */
@media (max-width: 576px) {
    .farms-page {
        margin-right: 0;
        padding: 0 8px 40px;
    }

    /* Breadcrumb */
    .breadcrumb {
        padding: 12px 0;
        flex-wrap: wrap;
    }

    .breadcrumb-text,
    .breadcrumb-current {
        font-size: 12px;
    }

    /* Page title */
    .farms-page-title {
        font-size: 15px;
    }

    .farms-page-description {
        font-size: 12px;
    }

    /* Tabs */
    .farms-tab-container-new {
        padding: 6px 8px;
    }

    .farms-tab-item-new {
        padding: 6px 12px;
        font-size: 12px;
    }

    /* Search container */
    .farms-search-container-new {
        padding: 12px;
        gap: 12px;
    }

    /* Inputs */
    .farms-search-input,
    .farms-filter-dropdown-new,
    .activity-multi-select-btn {
        height: 36px;
        font-size: 13px;
    }

    /* Buttons */
    .farms-create-button {
        height: 36px;
        font-size: 13px;
        padding: 8px 12px;
    }

    /* Modal footer buttons */
    .create-ranch-footer {
        flex-direction: column;
        gap: 8px;
    }

    .create-ranch-footer button {
        width: 100%;
    }

    .view-allocations-footer {
        flex-direction: column;
        gap: 8px;
    }

    .view-allocations-footer button {
        width: 100%;
    }

    /* Pagination */
    .pagination-controls {
        flex-wrap: wrap;
        justify-content: center;
        gap: 4px;
    }

    .pagination-btn {
        padding: 6px 10px;
        font-size: 12px;
    }

    .go-to-page {
        flex-direction: column;
        gap: 4px;
        align-items: center;
    }

    .go-to-page input {
        width: 50px;
    }

    /* Table footer */
    .table-footer {
        padding: 12px;
    }

    .showing-text {
        font-size: 12px;
    }

    /* Expanded row details */
    .ranch-expanded-details,
    .activity-expanded-details {
        padding: 8px;
    }

    .practices-section-header,
    .pack-types-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .practices-section-title,
    .pack-types-section-title {
        font-size: 13px;
    }

    .create-practice-btn,
    .create-pack-type-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Extra small screens */
@media (max-width: 400px) {
    .farms-tab-strip-new {
        flex-direction: column;
        width: 100%;
    }

    .farms-tab-item-new {
        width: 100%;
        text-align: center;
    }

    .create-ranch-icon {
        width: 30px;
        height: 30px;
    }

    .create-ranch-title-block h2 {
        font-size: 16px;
    }

    .create-ranch-title-block p {
        font-size: 11px;
    }
}

/* ========== VALIDATION ALERT STYLES (like Crews.razor) ========== */
.create-alert {
    margin: 0 0 16px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    text-align: center;
}

.create-alert.alert-success {
    background: #DCFCE7;
    color: #166534;
    border: 1px solid #A7F3D0;
}

.create-alert.alert-danger {
    background: #FEE2E2;
    color: #991B1B;
    border: 1px solid #FECACA;
}
