/* Admin Panel Custom Styles */

/* Button Styles */
.btn {
    @apply font-semibold px-5 py-2.5 rounded-lg transition-all duration-300 focus:outline-none focus:ring-2 focus:ring-opacity-50 inline-flex items-center justify-center gap-2;
}

.btn-primary {
    @apply bg-white text-black border-2 border-[#F8901F] hover:bg-[#F8901F] hover:text-white hover:transform hover:scale-105 focus:ring-[#F8901F];
}

.btn-success {
    @apply bg-white text-black border-2 border-green-600 hover:bg-green-600 hover:text-white hover:transform hover:scale-105 focus:ring-green-500;
}

.btn-danger {
    @apply bg-white text-black border-2 border-red-600 hover:bg-red-600 hover:text-white hover:transform hover:scale-105 focus:ring-red-500;
}

.btn-secondary {
    @apply bg-white text-gray-700 border-2 border-gray-300 hover:bg-gray-100 hover:border-gray-400 focus:ring-gray-400;
}

.btn-sm {
    @apply px-3 py-1.5 text-sm;
}

.btn-lg {
    @apply px-8 py-3.5 text-lg;
}

.btn-icon {
    @apply w-10 h-10 p-0 rounded-full;
}

/* Admin action buttons inspired by hotel editor */
.action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border: 2px solid #ea580c;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    background-color: #fff;
    color: #111827;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.action-btn:hover {
    background-color: #ea580c;
    color: #fff;
}

.action-btn:focus-visible {
    outline: 2px solid rgba(234, 88, 12, 0.4);
    outline-offset: 2px;
}

.action-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.action-btn--solid {
    background-color: #ea580c;
    color: #fff;
}

.action-btn--solid:hover {
    background-color: #c2410c;
    border-color: #c2410c;
}

.action-btn--ghost {
    border-color: #d1d5db;
    color: #4b5563;
}

.action-btn--ghost:hover {
    background-color: #f3f4f6;
    color: #111827;
    border-color: #9ca3af;
}

.action-btn--danger {
    border-color: #f87171;
    color: #dc2626;
}

.action-btn--danger:hover {
    background-color: #ef4444;
    border-color: #ef4444;
    color: #fff;
}

.action-btn--sm {
    padding: 0.4rem 0.9rem;
    font-size: 0.75rem;
    border-radius: 0.45rem;
}

.action-btn--xs {
    padding: 0.25rem 0.7rem;
    font-size: 0.7rem;
    border-radius: 0.4rem;
    gap: 0.25rem;
}

/* Form Input Styles */
.form-input {
    @apply w-full px-4 py-3 border rounded-lg focus:outline-none focus:border-green-900 focus:ring-1 focus:ring-green-900 transition-colors;
    border-color: #CECECE;
}

.form-label {
    @apply block text-sm font-semibold text-gray-700 mb-2;
}

.form-select {
    @apply w-full px-4 py-3 border rounded-lg focus:outline-none focus:border-green-900 focus:ring-1 focus:ring-green-900 transition-colors;
    border-color: #CECECE;
}

.form-textarea {
    @apply w-full px-4 py-3 border rounded-lg focus:outline-none focus:border-green-900 focus:ring-1 focus:ring-green-900 transition-colors resize-y;
    border-color: #CECECE;
}

.form-checkbox {
    @apply w-4 h-4 text-green-900 border-gray-300 rounded focus:ring-green-900 focus:ring-2;
}

/* Card Styles */
.admin-card {
    @apply bg-white rounded-2xl shadow-lg border border-gray-100 p-6;
}

.admin-card-header {
    @apply font-bold text-2xl text-gray-900 mb-6 pb-4 border-b border-gray-200;
}

/* Table Styles */
.admin-table {
    @apply w-full border-collapse;
}

.admin-table thead {
    @apply bg-gray-50 border-b-2 border-gray-200;
}

.admin-table th {
    @apply px-6 py-4 text-left text-sm font-semibold text-gray-700 uppercase tracking-wider;
}

.admin-table td {
    @apply px-6 py-4 text-sm text-gray-900 border-b border-gray-100;
}

.admin-table tbody tr:hover {
    @apply bg-gray-50 transition-colors;
}

/* Badge Styles */
.badge {
    @apply inline-flex items-center px-3 py-1 rounded-full text-xs font-semibold;
}

.badge-success {
    @apply bg-green-100 text-green-800;
}

.badge-warning {
    @apply bg-yellow-100 text-yellow-800;
}

.badge-danger {
    @apply bg-red-100 text-red-800;
}

.badge-info {
    @apply bg-blue-100 text-blue-800;
}

.badge-secondary {
    @apply bg-gray-100 text-gray-800;
}

/* Modal Styles */
.modal-overlay {
    @apply fixed inset-0 bg-black bg-opacity-50 z-40 flex items-center justify-center p-4;
}

.modal-content {
    @apply bg-white rounded-2xl shadow-2xl max-w-2xl w-full max-h-[90vh] overflow-y-auto;
}

.modal-header {
    @apply px-6 py-4 border-b border-gray-200 flex justify-between items-center sticky top-0 bg-white z-10;
}

.modal-title {
    @apply text-xl font-bold text-gray-900;
}

.modal-body {
    @apply px-6 py-6;
}

.modal-footer {
    @apply px-6 py-4 border-t border-gray-200 flex justify-end gap-3 sticky bottom-0 bg-white;
}

/* Alert Styles */
.alert {
    @apply px-4 py-3 rounded-lg mb-4;
}

.alert-success {
    @apply bg-green-50 text-green-800 border border-green-200;
}

.alert-error {
    @apply bg-red-50 text-red-800 border border-red-200;
}

.alert-warning {
    @apply bg-yellow-50 text-yellow-800 border border-yellow-200;
}

.alert-info {
    @apply bg-blue-50 text-blue-800 border border-blue-200;
}

/* Image Upload Preview */
.image-preview {
    @apply relative rounded-lg overflow-hidden border-2 border-gray-200 hover:border-green-900 transition-colors;
}

.image-preview img {
    @apply w-full h-32 object-cover;
}

.image-preview-overlay {
    @apply absolute inset-0 bg-black bg-opacity-50 flex items-center justify-center opacity-0 hover:opacity-100 transition-opacity;
}

/* Loading Spinner */
.spinner {
    @apply inline-block w-5 h-5 border-2 border-current border-t-transparent rounded-full animate-spin;
}

/* Pagination */
.pagination {
    @apply flex items-center gap-2;
}

.pagination-btn {
    @apply px-3 py-2 border border-gray-300 rounded-lg hover:bg-gray-50 disabled:opacity-50 disabled:cursor-not-allowed transition-colors;
}

.pagination-btn.active {
    @apply bg-green-900 text-white border-green-900 hover:bg-green-800;
}

/* File Upload Area */
.file-upload-area {
    @apply border-2 border-dashed border-gray-300 rounded-lg p-8 text-center hover:border-green-900 transition-colors cursor-pointer;
}

.file-upload-area.dragover {
    @apply border-green-900 bg-green-50;
}

/* Utility Classes */
.section-title {
    @apply text-2xl font-bold text-gray-900 mb-6;
}

.section-subtitle {
    @apply text-gray-600 mb-4;
}

.divider {
    @apply border-t border-gray-200 my-6;
}

.grid-2 {
    @apply grid grid-cols-1 md:grid-cols-2 gap-6;
}

.grid-3 {
    @apply grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6;
}

.grid-4 {
    @apply grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6;
}
