/* Custom CSS for Homnex */

:root {
    --color-primary: #6ab32e;
    --color-primary-dark: #5a9826;
    --color-primary-light: #8bc34a;
}

/* Mobile app-like styles */
@media (max-width: 768px) {
    /* Basic padding for bottom navigation */
    main {
        padding-bottom: 70px;
    }
    
    /* Remove tap highlight color */
    body {
        -webkit-tap-highlight-color: transparent;
    }
    
    /* Smoother scrolling for iOS */
    body, .smooth-scroll {
        -webkit-overflow-scrolling: touch;
    }
    
    /* Full width containers on mobile */
    .container {
        max-width: 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    
    /* Add padding to content inside containers */
    .container > div:not(.md\\:hidden):not(.mobile-full-width) {
        margin-left: 1rem;
        margin-right: 1rem;
    }
    
    /* Rounded corners for cards on mobile */
    .bg-white.rounded-lg {
        border-radius: 1rem;
    }
    
    /* Larger touch targets for mobile */
    button, 
    select,
    input[type="date"],
    input[type="text"],
    input[type="email"],
    input[type="password"],
    input[type="number"],
    input[type="tel"] {
        min-height: 44px;
    }
    
    /* Mobile form styling */
    .form-container {
        background-color: white;
        border-radius: 1rem;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
        padding: 1.5rem;
        margin: 1rem;
    }
    
    /* Mobile card styling */
    .mobile-card {
        background-color: white;
        border-radius: 1rem;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
        padding: 1rem;
        margin-bottom: 1rem;
    }
    
    /* Mobile tab navigation */
    .mobile-tabs {
        display: flex;
        overflow-x: auto;
        white-space: nowrap;
        border-bottom: 1px solid #e5e7eb;
        margin-bottom: 1rem;
        -ms-overflow-style: none;
        scrollbar-width: none;
    }
    
    .mobile-tabs::-webkit-scrollbar {
        display: none;
    }
    
    .mobile-tab {
        padding: 0.75rem 1rem;
        font-weight: 500;
        font-size: 0.875rem;
        color: #6b7280;
        border-bottom: 2px solid transparent;
    }
    
    .mobile-tab.active {
        color: #6ab32e;
        border-bottom: 2px solid #6ab32e;
    }
    
    /* Mobile bottom sheet */
    .mobile-bottom-sheet {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background-color: white;
        border-top-left-radius: 1rem;
        border-top-right-radius: 1rem;
        box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
        z-index: 50;
        transform: translateY(100%);
        transition: transform 0.3s ease-in-out;
    }
    
    .mobile-bottom-sheet.active {
        transform: translateY(0);
    }
    
    /* Mobile floating action button */
    .mobile-fab {
        position: fixed;
        bottom: 5rem;
        right: 1rem;
        width: 3.5rem;
        height: 3.5rem;
        border-radius: 50%;
        background-color: #6ab32e;
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        z-index: 40;
    }
    
    /* Mobile sticky header */
    .mobile-sticky-header {
        position: sticky;
        top: 0;
        background-color: white;
        z-index: 30;
        padding: 0.75rem 1rem;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #6ab32e;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #5a9826;
}

/* Custom animations */
.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Hero section animations */
.animate-fadeIn {
    animation: fadeIn 1s ease-in-out forwards;
    opacity: 0;
}

.animate-slideUp {
    animation: slideUp 0.8s ease-in-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Text shadow utilities */
.text-shadow-sm {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.text-shadow-md {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.text-shadow-lg {
    text-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

/* Custom button styles */
.btn-primary {
    background-color: #6ab32e;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
    transition: background-color 0.3s;
}

.btn-primary:hover {
    background-color: #5a9826;
}

.btn-secondary {
    background-color: white;
    color: #6ab32e;
    border: 1px solid #6ab32e;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background-color: #f0f9e8;
}

/* Card hover effects */
.room-card {
    transition: transform 0.3s, box-shadow 0.3s;
}

.room-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Form styles */
.form-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    transition: border-color 0.3s;
}

.form-input:focus {
    outline: none;
    border-color: #6ab32e;
    box-shadow: 0 0 0 3px rgba(106, 179, 46, 0.2);
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #374151;
}

/* Checkbox styling */
input[type="checkbox"] {
    color: var(--color-primary);
    border-color: #d1d5db;
}

input[type="checkbox"]:checked {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
}

input[type="checkbox"]:focus {
    --tw-ring-color: var(--color-primary);
    --tw-ring-opacity: 0.5;
}

/* Custom checkbox */
.custom-checkbox {
    position: relative;
    padding-left: 30px;
    cursor: pointer;
    user-select: none;
}

.custom-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 20px;
    width: 20px;
    background-color: #eee;
    border-radius: 4px;
}

.custom-checkbox:hover input ~ .checkmark {
    background-color: #ccc;
}

.custom-checkbox input:checked ~ .checkmark {
    background-color: var(--color-primary, #6ab32e);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked ~ .checkmark:after {
    display: block;
}

.custom-checkbox .checkmark:after {
    left: 7px;
    top: 3px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}