Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <html>
<head>
    <title>Category Sitemap</title>
</head>
<body>
    <h1 class="title">Category Sitemap</h1>
<span class="display">Show: </span>
<input checked data-tooltip='first level' id='radio-1' name='test' type='radio' /><label for="radio-1">First level</label>
<input id='radio-2' data-tooltip='second level' name='test' type='radio' /><label for="radio-2">Second level</label>
<input id='radio-3' data-tooltip='third level' name='test' type='radio' /><label for="radio-3">Third level</label>


    <ol class="wtree">
        <li><span>Life</span>
            <ol>
                <li>
                    <span>Personal Issues</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Balancing Work and Life</span></li>
                        <li><span>Coping with Illness</span></li>
                        <li><span>Grief and Loss</span></li>
                        <li><span>Personal Growth</span></li>
                        <li><span>Stress Management</span></li>
                    </ol>
                </li>
                <li>
                    <span>Relationships</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Being Single</span></li>
                        <li><span>Couples</span></li>
                        <li><span>Cross-Cultural Concerns</span></li>
                        <li><span>Divorce/Separation - Emotional
                        Aspects</span></li>
                        <li><span>Family Relationships</span></li>
                        <li><span>Infertility</span></li>
                        <li><span>Non-Family Relationships</span></li>
                        <li><span>Neglect and Abuse</span></li>
                        <li><span>Gay/Lesbian</span></li>
                    </ol>
                </li>
                <li>
                    <span>Recreation</span>
                    <ol>
                        <li><span>Our StaffPicks</span></li>
                        <li><span>Planning Special Events</span></li>
                        <li><span>Travel and Vacations</span></li>
                    </ol>
                </li>
                <li>
                    <span>Home</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Buying or Selling a Home</span></li>
                        <li><span>Renting</span></li>
                        <li><span>Caring for or Renovating Your
                        Home</span></li>
                    </ol>
                </li>
                <li>
                    <span>Pets</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Pets</span></li>
                    </ol>
                </li>
                <li>
                    <span>Moving</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Making Connections in a New Community</span></li>
                        <li><span>Planning a Move</span></li>
                        <li><span>Living Abroad</span></li>
                    </ol>
                </li>
                <li>
                    <span>Military Life</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Military Deployment and Return</span></li>
                        <li><span>Military Family Issues</span></li>
                    </ol>
                </li>
                <li>
                    <span>Disabilities</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Accessing Services and Resources</span></li>
                        <li><span>Living with a Disability</span></li>
                        <li><span>Paying for CareSpecific
                        Disabilities</span></li>
                        <li><span>Children with S</span></li>
                        <li><span>Special Needs</span></li>
                        <li><span>Caregiver Support for People with
                        Disabilities</span></li>
                    </ol>
                </li>
                <li>
                    <span>Crisis</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Natural Disaster</span></li>
                        <li><span>State and Local Resources</span></li>
                        <li><span>Sexual Assault</span></li>
                        <li><span>Suicide</span></li>
                        <li><span>Violence and Trauma</span></li>
                    </ol>
                </li>
                <li>
                    <span>Legal</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Consumer Protection</span></li>
                        <li><span>Criminal Law</span></li>
                        <li><span>Divorce/Separation - Legal Issues</span></li>
                        <li><span>Estate/Probate/Wills</span></li>
                        <li><span>Hiring and Working with a Lawyer</span></li>
                        <li><span>Immigration, Visas, and
                        Citizenship</span></li>
                        <li><span>Advance Directives/Living Wills</span></li>
                        <li><span>Bankruptcy</span></li>
                        <li><span>Collections and Consumer Rights</span></li>
                        <li><span>Family Law</span></li>
                        <li><span>Other Legal Matters</span></li>
                    </ol>
                </li>
                <li>
                    <span>Midlife</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Friendships and Relationships in Midlife</span></li>
                        <li><span>Growing as a Couple</span></li>
                        <li><span>Life Planning/Priorities in Midlife</span></li>
                        <li><span>Midlife Health</span></li>
                        <li><span>Relationships with Adult Children</span></li>
                        <li><span>Work and Career in Midlife</span></li>
                    </ol>
                </li>
                <li>
                    <span>Retirement</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Education/Work/Volunteer
                        Opportunities</span></li>
                        <li><span>Financial Considerations for
                        Retirement</span></li>
                        <li><span>Making the Transition to
                        Retirement</span></li>
                        <li><span>Planning for Life in Retirement</span></li>
                        <li><span>Travel in Later Life</span></li>
                    </ol>
                </li>
            </ol>
        </li>


        <li>
            <span>Health</span>
            <ol>
                <li>
                    <span>Health Habits</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Diet and Nutrition</span></li>
                        <li><span>Fitness and Exercise</span></li>
                        <li><span>Safety/Self Care</span></li>
                        <li><span>Sleep Health</span></li>
                        <li><span>Stress</span></li>
                        <li><span>Tobacco</span></li>
                        <li><span>Weight Management</span></li>
                    </ol>
                </li>
                <li>
                    <span>Diseases/Conditions</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Allergies/Asthma</span></li>
                        <li><span>Cancer</span></li>
                        <li><span>Cholesterol/Heart Disease</span></li>
                        <li><span>Chronic Conditions and Diseases</span></li>
                        <li><span>Other Diseases/Conditions</span></li>
                    </ol>
                </li>
                <li>
                    <span>Mental Health</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>ADD and ADHD</span></li>
                        <li><span>Anger Management</span></li>
                        <li><span>Anxiety</span></li>
                        <li><span>Depression</span></li>
                        <li><span>Eating Disorders</span></li>
                        <li><span>Mood Disorders</span></li>
                        <li><span>Other Mental Health Issues</span></li>
                        <li><span>Personality Disorders</span></li>
                    </ol>
                </li>
                <li>
                    <span>Children</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Children&#8217;s Mental Health</span></li>
                        <li><span>Childhood Disease</span></li>
                        <li><span>Fitness and Nutrition for
                        Children</span></li>
                        <li><span>Children&#8217;s Safety</span></li>
                        <li><span>Abuse and Neglect of Children</span></li>
                    </ol>
                </li>
                <li>
                    <span>Adults</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Infertility</span></li>
                        <li><span>Men&#8217;s Health</span></li>
                        <li><span>Women&#8217;s Health</span></li>
                        <li><span>Prenatal Health/Pregnancy</span></li>
                    </ol>
                </li>
                <li>
                    <span>Seniors</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Fitness and Nutrition in Later
                        Life</span></li>
                        <li><span>Assistive Devices</span></li>
                        <li><span>Home Safety</span></li>
                        <li><span>Hospitalization and
                        Rehabilitation</span></li>
                        <li><span>Senior Mental Health</span></li>
                        <li><span>Physical Changes/Medical
                        Information/Evaluations</span></li>
                        <li><span>Vision and Hearing</span></li>
                    </ol>
                </li>
                <li>
                    <span>Addiction</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Alcohol and Drugs</span></li>
                        <li><span>Concern About Others</span></li>
                        <li><span>Compulsive Behaviors</span></li>
                        <li><span>Compulsive Gambling</span></li>
                        <li><span>Other Addictions</span></li>
                    </ol>
                </li>
                <li>
                    <span>Pain</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Back/Neck/Shoulder/Joint Pain</span></li>
                        <li><span>Ergonomics and Repetitive Motion</span></li>
                        <li><span>Headaches</span></li>
                    </ol>
                </li>
                <li><span>Health Care/Insurance</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Alternative Care/Medicine</span></li>
                        <li><span>Health Care Providers/Insurance</span></li>
                    </ol>
                </li>
            </ol>
        </li>
        <li>
            <span>Family</span>
            <ol>
                <li>
                    <span>Couples</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Couples</span></li>
                        <li><span>Cross-Cultural Concerns</span></li>
                        <li><span>Family Relationships</span></li>
                        <li><span>Infertility</span></li>
                        <li><span>Neglect and Abuse</span></li>
                        <li><span>Family Law</span></li>
                        <li><span>Relationships with Adult Children</span></li>
                        <li><span>Gay/Lesbian</span></li>
                    </ol>
                </li>
                <li>
                    <span>Divorce/Separation</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Divorce/Separation - Emotional
                        Aspects</span></li>
                        <li><span>Divorce/Separation - Legal Issues</span></li>
                        <li><span>Divorce/Separation - Impact on
                        Children</span></li>
                        <li><span>Custody, Visitation, and Child
                        Support</span></li>
                    </ol>
                </li>
                <li>
                    <span>Adoption</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Adopting Step or Foster Children</span></li>
                        <li><span>Adoption Legal Issues</span></li>
                        <li><span>Adoption Options</span></li>
                        <li><span>Raising an Adopted Child</span></li>
                        <li><span>Understanding the Adoption
                        Process</span></li>
                    </ol>
                </li>
                <li>
                    <span>Becoming a Parent</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Caring for a New
                        Baby/Breastfeeding</span></li>
                        <li><span>Planning for Parenthood</span></li>
                        <li><span>Pregnancy</span></li>
                        <li><span>Pregnancy Loss/Birth
                        Complications</span></li>
                    </ol>
                </li>
                <li>
                    <span>Parenting</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Children with Special Needs</span></li>
                        <li><span>Childhood Stages: Early School
                        Years</span></li>
                        <li><span>Childhood Stages: Infants</span></li>
                        <li><span>Childhood Stages: Pre-Teen/Middle School
                        Years</span></li>
                        <li><span>Childhood Stages: Teenager/High School
                        Years</span></li>
                        <li><span>Childhood Stages: Toddler/Preschool
                        Years</span></li>
                        <li><span>Advocating for Children</span></li>
                        <li><span>Balancing Work and Family</span></li>
                        <li><span>Children and Stress</span></li>
                        <li><span>Choosing Children&#8217;s
                        Products</span></li>
                        <li><span>Communicating with Your Kids</span></li>
                        <li><span>Discipline/Responsible Behavior</span></li>
                        <li><span>Family Relocation</span></li>
                        <li><span>Grandparents/Extended Family</span></li>
                        <li><span>Relatives Raising Children</span></li>
                        <li><span>Sibling Relationships</span></li>
                        <li><span>Single Parenting</span></li>
                        <li><span>Step parenting</span></li>
                        <li><span>Parenting and Household
                        Responsibilities</span></li>
                    </ol>
                </li>
                <li>
                    <span>Child Care</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Finding Child Care</span></li>
                        <li><span>Backup Child Care</span></li>
                        <li><span>Communicating with Child Care
                        Providers</span></li>
                        <li><span>Child Care Choices</span></li>
                        <li><span>Informal Child Care/Babysitters</span></li>
                        <li><span>In-Home Care - Nannies/Au Pairs</span></li>
                        <li><span>Nursery Schools/Pre-K Programs</span></li>
                        <li><span>Paying for Child Care</span></li>
                        <li><span>School-Age Care/Camps</span></li>
                    </ol>
                </li>
                <li>
                    <span>Education</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Parent Involvement at School</span></li>
                        <li><span>School Transitions/Changes</span></li>
                        <li><span>Advocating in the Schools</span></li>
                        <li><span>Special Programs</span></li>
                        <li><span>Alternatives to College</span></li>
                        <li><span>Adjusting to College</span></li>
                        <li><span>Applying to College</span></li>
                        <li><span>Financial Aid and Scholarships</span></li>
                        <li><span>Home Schooling</span></li>
                        <li><span>Study Skills, Tests, and Tutoring</span></li>
                        <li><span>School Selection</span></li>
                    </ol>
                </li>
                <li>
                    <span>Older Relatives</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Advocacy and Rights</span></li>
                        <li><span>Staying Active and Engaged</span></li>
                        <li><span>Care Planning</span></li>
                        <li><span>Adult Day Care</span></li>
                        <li><span>Home Care, Home Health, and Chore
                        Services</span></li>
                        <li><span>Community Resources</span></li>
                        <li><span>Continuing Care/Retirement
                        Communities</span></li>
                        <li><span>Independent Living</span></li>
                        <li><span>Living with an Older Relative</span></li>
                        <li><span>Nursing Homes</span></li>
                        <li><span>Housing Options</span></li>
                        <li><span>Paying for Care/Medicare/Medicaid</span></li>
                        <li><span>Caregiver Resources</span></li>
                    </ol>
                </li>
                <li>
                    <span>Death/Loss</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Grief and Loss</span></li>
                        <li><span>Estate/Probate/Wills</span></li>
                        <li><span>End-of-Life Decisions</span></li>
                        <li><span>Funeral Planning</span></li>
                        <li><span>Hospice</span></li>
                    </ol>
                </li>
            </ol>
        </li>
        <li>
            <span>Work</span>
            <ol>
                <li>
                    <span>Work Effectiveness</span>
                    <ol>
                        <li><span>Our Staff PicksBusiness TravelManaging Change
                        at Work</span></li>
                        <li><span>Planning for and Returning from
                        Leave</span></li>
                        <li><span>Time Management at Work</span></li>
                        <li><span>Work Stress</span></li>
                        <li><span>Career Development</span></li>
                    </ol>
                </li>
                <li>
                    <span>Work Relationships</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Communication</span></li>
                        <li><span>Dealing with Co-Workers</span></li>
                        <li><span>Dealing with Your
                        Manager/Supervisor</span></li>
                        <li><span>Diversity in the Workplace</span></li>
                    </ol>
                </li>
                <li>
                    <span>Career</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Career Planning</span></li>
                        <li><span>Finding a Job</span></li>
                        <li><span>Training/Skills</span></li>
                        <li><span>Continuing Education</span></li>
                        <li><span>Working Abroad</span></li>
                        <li><span>Networking</span></li>
                    </ol>
                </li>
                <li>
                    <span>For Managers</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Developing Skills as a Manager</span></li>
                        <li><span>Manager Communication Skills</span></li>
                        <li><span>Managing Workload/Distribution</span></li>
                        <li><span>Managing Flexible
                        Schedules/Telework</span></li>
                        <li><span>Managing Teams</span></li>
                        <li><span>Managing Performance</span></li>
                        <li><span>Managing Workplace Change</span></li>
                        <li><span>Diversity, Managing for Inclusion</span></li>
                        <li><span>Leadership/Motivation</span></li>
                        <li><span>Managing Employee Absences/Leave</span></li>
                        <li><span>Time Management for
                        Managers/Delegation</span></li>
                        <li><span>Managing Employee Problems</span></li>
                        <li><span>Promoting a Drug-Free Workplace</span></li>
                        <li><span>Workplace Violence/Risk of
                        Violence</span></li>
                    </ol>
                </li>
                <li>
                    <span>Work Hours/Flexibility</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Flexible Work Schedules</span></li>
                        <li><span>Shift Work</span></li>
                        <li><span>Telework</span></li>
                    </ol>
                </li>
                <li>
                    <span>Work Transitions</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Job Loss</span></li>
                        <li><span>Relocating for Work</span></li>
                    </ol>
                </li>
                <li>
                    <span>Leave/Time Off</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Leave/Time-Off</span></li>
                    </ol>
                </li>
                <li>
                    <span>Work Safety</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Preventing Workplace Violence</span></li>
                    </ol>
                </li>
            </ol>
        </li>
        <li>
            <span>Money</span>
            <ol>
                <li>
                    <span>Budgeting</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Budgeting and Basic Money
                        Management</span></li>
                        <li><span>Loans/Consolidation of Loans</span></li>
                        <li><span>Overextended with Bills</span></li>
                    </ol>
                </li>
                <li>
                    <span>Debt</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Bankruptcy</span></li>
                        <li><span>Collections and Consumer Rights</span></li>
                        <li><span>Managing Your Credit</span></li>
                    </ol>
                </li>
                <li>
                    <span>Saving</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Investing for Retirement</span></li>
                        <li><span>Choosing a Financial Planner</span></li>
                        <li><span>Life and Long-Term Care Insurance</span></li>
                        <li><span>Saving and Investing Basics</span></li>
                    </ol>
                </li>
                <li>
                    <span>Financial Emergencies</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Financial Fraud/Identity Theft</span></li>
                        <li><span>Emergency Financial Resources</span></li>
                    </ol>
                </li>
                <li>
                    <span>Home Buying or Renting</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Buying or Selling a Home</span></li>
                        <li><span>Renting</span></li>
                        <li><span>Home/Rental Insurance</span></li>
                        <li><span>Mortgages/Refinancing</span></li>
                    </ol>
                </li>
                <li>Taxes
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Tax Planning and Preparation</span></li>
                    </ol>
                </li>
                <li>
                    <span>Shopping/Services</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Planning Special Events</span></li>
                        <li><span>Travel and Vacations</span></li>
                        <li><span>Community Resources</span></li>
                        <li><span>Consumer Purchases</span></li>
                    </ol>
                </li>
                <li>
                    <span>Cars/Transportation</span>
                    <ol>
                        <li><span>Our Staff Picks</span></li>
                        <li><span>Car Insurance and Maintenance</span></li>
                        <li><span>Buying, Selling, or Leasing a Car</span></li>
                        <li><span>Other Transportation Options</span></li>
                    </ol>
                </li>
            </ol>
        </li>
    </ol>
</body>
</html>
              
            
!

CSS

              
                $border: #ddd;
$border-hover: rgb(71,71,71);
$bg-hover: rgba(0,0,0,.1);
$text: rgba(102,102,102,1);
$text-hover: #000;
$ident: 30px;
$left: -($ident);
$first:#DDF3FE;
$second:#DDEBC8;
$third:#FEFCD5;

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

body {
  padding:50px;
  font-family:'Helvetica Neue', Helvetica,  Arial, sans-serif;
  letter-spacing: normal;
}
h1{
  padding: 0 0 10px 0;
}
ol {
  margin-left:$ident;
  counter-reset: item;
}

.wtree {
  li {
    list-style-type: none;
    margin:10px 0 10px 10px;
    position: relative;
    &:before {
      content: "";
      counter-increment: item; 
      position: absolute;
      top:-10px;
      left:$left;
      border-left: 1px solid $border;
      border-bottom:1px solid $border;
      width:$ident;
      height:15px;
    }
    &:after {
      position:absolute;
      content:"";
      top:5px;
      left:$left;
      border-left: 1px solid $border;
      border-top:1px solid $border;
      width:$ident;
      height:100%;
    }
    &:last-child:after {
      display:none;
    }
    span {
      display:block;
      border: 1px solid $border;
      padding:10px;
      color:$text;
      text-decoration:none;
      &:before{ 
      content: counters(item, ".") " ";    
    }
    }
  }
}

.wtree {
  li {
    span {
      &:hover,
      &:focus { 
        color: $text-hover; 
        border: 1px solid $border-hover;
        & + ol {
          li {
            span {
              color: $text-hover; 
              border: 1px solid $border-hover;
            }
          }
        }
      }

      &:hover + ol, 
      &:focus + ol {
        li {
          &:after,&:before {
            border-color:  $border-hover;
          }
        }
      }
    }
  }
}

li span {background-color:$first}
li li span{background-color:$second}
li li li span{background-color:$third}

.display{
  margin-right:12px;
  font-weight:bold;
}

input , label{
  margin:12px 0px 20px 0px;
}

label {
    padding-left: 6px;
    padding-right: 12px;
}

#radio-1:checked+label ~ ol li ol li {display: none;}
#radio-2:checked+label ~ ol li ol li ol li  {display: none;}
#radio-3:checked+label ~ li ol li ol li {display: none;}
              
            
!

JS

              
                
              
            
!
999px

Console