/* profile.css - Mobile-First Profile Styles */
:root {
    --primary: #6C63FF;
    --primary-light: #8B85FF;
    --dark: #2D3748;
    --light: #F7FAFC;
    --gray: #64748B;
    --light-gray: #E2E8F0;
    --white: #FFFFFF;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
}

/* Base Styles */
.profile-page {
    font-family: 'Poppins', sans-serif;
    background-color: var(--light);
    color: var(--dark);
    min-height: 100vh;
    padding-bottom: 1rem;
}

/* App Bar */
.app-bar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    padding: 1rem;
    background: var(--white);
    box-shadow: var(--shadow-sm);
}

.back-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: var(--dark);
    padding: 0.5rem;
    margin-right: 0.5rem;
}

.app-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.spacer {
    flex: 1;
}

/* Main Container */
.profile-container {
    padding: 0 1rem;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

.profile-card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    width: 100%;
    box-sizing: border-box;
}

/* Profile Header */
.profile-header {
    padding: 1.5rem 1rem;
    text-align: center;
    border-bottom: 1px solid var(--light-gray);
}

.avatar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.avatar-edit {
    position: relative;
    margin-bottom: 1rem;
}

.logo-preview {
    
    
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    overflow: hidden;
}

.logo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.default-icon {
    opacity: 0.8;
}

.edit-avatar-btn {
    position: absolute;
    bottom: -5px;
    right: -5px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    border: 2px solid var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.business-name {
    font-size: 1.3rem;
    margin: 0.5rem 0 0;
    word-break: break-word;
    max-width: 100%;
}

/* Form Sections */
.form-section {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid var(--light-gray);
    box-sizing: border-box;
}

.section-title {
    display: flex;
    align-items: center;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    color: var(--dark);
}

.section-icon {
    margin-right: 0.5rem;
    color: var(--primary);
    font-size: 1rem;
}

/* Input Groups */
.input-group {
    margin-bottom: 1.2rem;
    width: 100%;
    box-sizing: border-box;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--dark);
}

.input-with-icon {
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.input-with-icon i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    font-size: 0.9rem;
}

.input-with-icon input,
.input-with-icon textarea {
    width: calc(100% - 2.5rem);
    padding: 0.8rem 1rem 0.8rem 2.5rem;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius-sm);
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    transition: all 0.2s;
    box-sizing: border-box;
}

.input-with-icon textarea {
    min-height: 80px;
    resize: vertical;
}

.input-with-icon input:focus,
.input-with-icon textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}

/* Logo Options */
.logo-options {
    margin-top: 0.5rem;
    width: 100%;
    box-sizing: border-box;
}

.option-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.8rem;
    background: var(--white);
    border: 1px solid var(--light-gray);
    border-radius: var(--radius-sm);
    color: var(--dark);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    box-sizing: border-box;
}

.option-btn:hover {
    background: var(--light);
    border-color: var(--primary-light);
}

.option-btn i {
    color: var(--primary);
}

.option-divider {
    text-align: center;
    margin: 1rem 0;
    color: var(--gray);
    font-size: 0.75rem;
    position: relative;
}

.option-divider:before,
.option-divider:after {
    content: "";
    position: absolute;
    top: 50%;
    width: 30%;
    height: 1px;
    background: var(--light-gray);
}

.option-divider:before {
    left: 0;
}

.option-divider:after {
    right: 0;
}

.icon-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
    width: 100%;
}

.icon-option {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1/1;
    border-radius: var(--radius-sm);
    background: var(--light);
    color: var(--gray);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
}

.icon-option:hover {
    background: var(--primary-light);
    color: white;
}

.icon-option.active {
    background: var(--primary);
    color: white;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 0.8rem;
    padding: 1.5rem 1rem;
    width: 100%;
    box-sizing: border-box;
}

.action-btn {
    flex: 1;
    padding: 0.9rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    box-sizing: border-box;
}

.action-btn.secondary {
    background: var(--white);
    color: var(--gray);
    border: 1px solid var(--light-gray);
}

.action-btn.secondary:hover {
    background: var(--light);
}

.action-btn.primary {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-sm);
}

.action-btn.primary:hover {
    background: var(--primary-light);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Responsive Adjustments */
@media (min-width: 768px) {
    .profile-container {
        padding: 2rem;
    }

    .profile-card {
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-md);
    }

    .profile-header {
        padding: 2rem;
    }

    .logo-preview {
        width: 100px;
        height: 100px;
        font-size: 2.5rem;
    }

    .business-name {
        font-size: 1.5rem;
    }

    .form-section {
        padding: 2rem;
    }

    .section-title {
        font-size: 1.1rem;
    }

    .icon-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .form-actions {
        padding: 2rem;
    }
}


/* Icon Grid Enhancements */
.icon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.icon-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem 0.5rem;
    border-radius: var(--radius-sm);
    background: var(--light);
    color: var(--gray);
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    aspect-ratio: 1/1;
}

.icon-option i {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.icon-tooltip {
    position: absolute;
    bottom: -25px;
    background: var(--dark);
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    opacity: 0;
    transition: all 0.3s;
    pointer-events: none;
    white-space: nowrap;
    z-index: 10;
}

.icon-option:hover .icon-tooltip {
    opacity: 1;
    bottom: -30px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .icon-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .icon-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Logo Grid Styles */
.logo-grid-container {
    margin-top: 1.5rem;
}

.logo-options-title {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 1rem;
    font-weight: 500;
}

.logo-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

.logo-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 0.5rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--light-gray);
    cursor: pointer;
    transition: all 0.3s;
}

.logo-option:hover {
    border-color: var(--primary-light);
    transform: translateY(-3px);
}

.logo-option.active {
    border: 2px solid var(--primary);
    background-color: rgba(108, 99, 255, 0.05);
}

.logo-thumbnail {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.logo-label {
    font-size: 0.75rem;
    color: var(--dark);
    text-align: center;
    font-weight: 500;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .logo-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .logo-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.logo-thumbnail {
    width: 40px;
    height: 40px;
    display: block;
    margin: 0 auto;
}

.action-btn.primary {
    font-weight: 600; /* Semi-bold (Poppins supports 300-700) */
    /* OR */
    font-weight: bold; /* Explicit bold */
}