/* Frontend Page Styles - Linktree Inspired */
:root {
    --primary-color: #8129D9;
    /* Default, will be overridden by inline styles */
    --background: #ffffff;
    --text-color: #000000;
    --button-bg: #ffffff;
    --button-border: #e0e0e0;
    --button-text: #000000;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background: var(--background);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    line-height: 1.5;
}

.container {
    width: 100%;
    max-width: 100%;
    /* Override Bootstrap's responsive max-widths */
    padding-right: 15px;
    padding-left: 15px;
    margin-right: auto;
    margin-left: auto;
    background: transparent;
}

@media (min-width: 1200px) {

    .container,
    .container-lg,
    .container-md,
    .container-sm,
    .container-xl {
        max-width: 540px;
    }
}

/* Profile Section */
.profile {
    text-align: center;
    margin-bottom: 32px;
}

.profile-image-container {
    margin-bottom: 16px;
    display: inline-block;
    position: relative;
}

.profile-image {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
    background-color: #f0f0f0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.business-name {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    color: inherit;
    letter-spacing: -0.5px;
}

.bio {
    font-size: 16px;
    opacity: 0.9;
    line-height: 1.6;
    max-width: 540px;
    margin: 0 auto 16px;
    /*white-space: pre-wrap;*/
    /* Preserve newlines */
}

/* Links Section */
.links {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}

.link-button {
    display: flex;
    align-items: center;
    justify-content: center;
    /* Centered by default */
    position: relative;
    padding: 16px 24px;
    background: var(--button-bg);
    border: 2px solid transparent;
    /* Prepare for border */
    text-decoration: none;
    color: var(--button-text);
    font-weight: 600;
    font-size: 16px;
    transition: all 0.25s cubic-bezier(0.08, 0.59, 0.29, 0.99);
    min-height: 56px;
    width: 100%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Button Styles */
.btn-rounded {
    border-radius: 12px;
}

.btn-pill {
    border-radius: 9999px;
}

.btn-square {
    border-radius: 0;
}

/* Button Hover Effects */
.link-button:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
    text-decoration: none;
    color: var(--button-text);
}

.link-button:active {
    transform: scale(0.98);
}

/* Link Icon Styling */
.link-icon {
    position: absolute;
    left: 20px;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.link-text {
    text-align: center;
    width: 100%;
    z-index: 1;
}

/* Social Icons */
.social-icons-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: auto;
    flex-wrap: wrap;
}

.social-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    /* Default circle */
    background: rgba(255, 255, 255, 0.9);
    color: var(--primary-color);
    font-size: 22px;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.social-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    background: var(--primary-color);
    color: #ffffff;
}

/* Info Card */
.info-card {
    background: rgba(255, 255, 255, 0.95);
    border-left: 4px solid var(--primary-color);
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 24px;
    text-align: left;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    color: #333;
}

/* Opening Hours */
.opening-hours {
    margin-top: 32px;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 12px;
    font-size: 14px;
    display: none;
    /* Hidden by default if empty */
}

/* Branding Footer */
.branding {
    margin-top: 40px;
    font-size: 12px;
    opacity: 0.6;
    text-align: center;
}

.branding a {
    color: inherit;
    text-decoration: none;
    font-weight: 600;
}

/* Dark Mode Adjustments */
/* If background is dark (handled by inline PHP usually, but here are some overrides if needed) */
.dark-theme .social-icon {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.dark-theme .social-icon:hover {
    background: #ffffff;
    color: var(--primary-color);
}

/* Responsive */
@media (max-width: 480px) {
    body {
        padding: 30px 16px;
    }

    .profile-image {
        width: 80px;
        height: 80px;
    }

    .business-name {
        font-size: 20px;
    }

    .link-button {
        padding: 14px 20px;
        font-size: 15px;
        min-height: 50px;
    }

    .link-icon {
        font-size: 20px;
        left: 16px;
    }
}