/* SAC Registry Styles */

/* General */
.sac-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sac-form label {
    display: block;
    margin-bottom: 15px;
    font-weight: bold;
}

.sac-form input[type="text"],
.sac-form input[type="email"],
.sac-form input[type="date"],
.sac-form select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-top: 5px;
}

.sac-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .sac-grid {
        grid-template-columns: 1fr;
    }
}

.sac-note {
    font-size: 0.8em;
    color: #666;
    font-weight: normal;
}

/* Status labels */
.sac-status {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.8em;
    font-weight: bold;
    text-transform: uppercase;
}

.sac-green {
    background: #d4edda;
    color: #155724;
}

.sac-yellow {
    background: #fff3cd;
    color: #856404;
}

.sac-red {
    background: #f8d7da;
    color: #721c24;
}

.sac-purple {
    background: #e2d4f0;
    color: #5a2c82;
}

/* Status banners */
.sac-status-banner {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-weight: bold;
}

.sac-status-banner.sac-approved {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.sac-status-banner.sac-expired {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.sac-status-banner.sac-pending {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.sac-status-banner.sac-denied {
    background: #e2d4f0;
    color: #5a2c82;
    border: 1px solid #d4c4e4;
}

/* Alerts */
.sac-alert {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.sac-alert.sac-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.sac-alert.sac-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.sac-alert.sac-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

/* Dog listings */
.sac-row {
    display: flex;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.sac-row:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.sac-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 15px;
}

.sac-meta {
    flex: 1;
}

.sac-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.sac-name {
    font-weight: bold;
    font-size: 1.1em;
}

.sac-line {
    margin-bottom: 5px;
    color: #555;
}

.sac-actions {
    margin-top: 10px;
}

.sac-actions .button {
    margin-right: 5px;
    margin-bottom: 5px;
}

.sac-actions h4 {
    margin: 10px 0 5px;
    font-size: 0.9em;
    color: #666;
}

/* Dog detail */
.sac-dog {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 4px;
    margin-top: 20px;
}

.sac-dog-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.sac-dog-head h3 {
    margin: 0;
}

.sac-badge {
    background: #d4edda;
    color: #155724;
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 0.9em;
    font-weight: bold;
}

.sac-dog-fields {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sac-dog-fields li {
    margin-bottom: 10px;
}

/* Admin styles */
.sac-admin-tabs {
    margin-top: 20px;
}

.sac-tab-nav {
    display: flex;
    border-bottom: 1px solid #ccc;
    margin-bottom: 20px;
}

.sac-tab-nav a {
    padding: 10px 15px;
    margin-right: 5px;
    text-decoration: none;
    border: 1px solid transparent;
    border-bottom: none;
    border-radius: 4px 4px 0 0;
    background: #f5f5f5;
    color: #555;
}

.sac-tab-nav a.active {
    background: #fff;
    border-color: #ccc;
    color: #000;
    margin-bottom: -1px;
    padding-bottom: 11px;
}

.sac-tab-content {
    display: none;
    padding: 20px;
    border: 1px solid #ccc;
    border-top: none;
    background: #fff;
}

.sac-tab-content.active {
    display: block;
}

.sac-download-links {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.sac-download-link {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
}

.sac-download-link h4 {
    margin-top: 0;
    margin-bottom: 10px;
}

.sac-copy-link {
    width: 100%;
    margin-top: 10px;
    font-size: 0.8em;
    padding: 5px;
}

.sac-qr-test {
    margin-top: 20px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
}

.sac-quick-actions {
    margin-bottom: 20px;
}

.sac-quick-approve {
    background: #28a745;
    border-color: #28a745;
    color: #fff;
}

.sac-quick-deny {
    background: #dc3545;
    border-color: #dc3545;
    color: #fff;
}

.sac-quick-expire {
    background: #ffc107;
    border-color: #ffc107;
    color: #212529;
}

/* Dashboard widget */
.sac-dashboard-stats {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.sac-stat {
    flex: 1;
    min-width: 100px;
    padding: 10px;
    text-align: center;
    background: #f5f5f5;
    border-radius: 4px;
    margin-right: 10px;
    margin-bottom: 10px;
}

.sac-stat:last-child {
    margin-right: 0;
}

.sac-stat-number {
    display: block;
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 5px;
}

.sac-stat-total {
    background: #e2e2e2;
}

.sac-recent-activity {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sac-recent-activity li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.sac-recent-activity li:last-child {
    border-bottom: none;
}

.sac-time-ago {
    font-size: 0.8em;
    color: #777;
}

/* Tools page */
.sac-tools-section {
    margin-bottom: 30px;
}

.sac-success {
    color: #155724;
}

.sac-error {
    color: #721c24;
}

/* Footer */
.sac-footer {
    text-align: center;
    padding: 10px;
    margin-top: 20px;
    font-size: 0.8em;
    color: #777;
    border-top: 1px solid #eee;
}

/* Debug info */
.sac-debug {
    margin-top: 30px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
    font-size: 0.9em;
}

.sac-debug h3 {
    margin-top: 0;
    color: #666;
}

/* Places autocomplete */
.sac-places {
    margin-bottom: 20px;
}

.pac-container {
    z-index: 10000;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    border: 1px solid #ddd;
}

.pac-item {
    padding: 8px;
    cursor: pointer;
}

.pac-item:hover {
    background-color: #f5f5f5;
}

.pac-item-selected {
    background-color: #e9ecef;
}

/* Print styles */
@media print {
    .sac-card {
        box-shadow: none;
        border: none;
    }
    
    .sac-actions,
    .sac-debug {
        display: none;
    }
}
